Commits
Click on a commit to change the comparison rangefix(semantic): handle edge cases checking `super` (#13499)
Fixes #13284.
Fix semantic's checking of `super()` and `super.prop`.
This fixes various TS test cases, notably correctly identifying that these are all illegal:
```js
class C {
prop = function() { super.foo };
[super.foo]() {}
@super.foo method() {}
};
```
It also fixes various edge cases related to classes nested within other classes that aren't covered by existing conformance tests.
It's pretty much a complete re-write. I've combined the 2 paths for in a class and not in a class into one, to avoid repeated code.
This PR includes pass + fail test fixtures which include `super` in every conceivable position I could think of. There are so many errors in the fail test fixtures, that I had to write a script to check the snapshot includes them all!
Hopefully this solves this issue for once and for all!
Note: The large pass fixture seems to be revealing bugs somewhere in transformer - there's a mismatch, as well as lots of wrong scopes. But that's incidental to this PR, and can be addressed separately.2 months ago
by overlookmotel