-
Notifications
You must be signed in to change notification settings - Fork 2k
Compiler error when calling super
from a method named with a reserved word
#2949
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
Comments
Seems to come from Literal::compileNode() wrapping. Will look when I get home :). |
Nice catch. |
Looks like we don't have the EDIT : nop, looked for almost 2hours, nothing comes to my mind :p. |
This seems to have been fixed. It's an error outside of an instance method, and gets quoted properly when used in one. |
The "Cannot call super outside of an instance method" error only gets generated when the method is named with a reserved word (just re-verified using "Try Coffeescript" at coffeescript.org). Please reopen. |
* Fixes jashkenas#2949: Detect reserved names (not only for instance methods) * Don't assign names which might result in incorrect `super` calls
Example:
Note that these both compile fine:
The text was updated successfully, but these errors were encountered: