Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SuperCall incorrectly tolerated in constructors of classes with no lineage #3536

Open
jugglinmike opened this issue Feb 21, 2021 · 2 comments

Comments

@jugglinmike
Copy link
Member

As of version 2.12.0, JSHint incorrectly allows SuperCall expression to appear in the constructor function of classes which do not define a lineage.

For example, the following text contains a syntax error, but JSHint does not recognize it:

/* jshint esversion: 6 */
class C {
  constructor() {
    super();
  }
}
@jugglinmike jugglinmike added the P3 label Feb 21, 2021
@nicolo-ribaudo
Copy link
Contributor

There is this old PR I opened: #2572

There are conflicts in every file it touches so probably it's easier for someone to open a new one rather than trying to rebase my PR, but there might be some useful review comments or ideas in the code.

@jugglinmike
Copy link
Member Author

Thanks, @nicolo-ribaudo! That's some memory you've got :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants