-
Notifications
You must be signed in to change notification settings - Fork 332
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
E2 does not recognize local variables inside events defined outside of them when included in another file #3224
Comments
Here is the code in text form:
|
A friend of mine experimented with this bug and seems to have found the culprit of the error:
and
seem to produce the same error. |
Might need to persist it. This looks more like a programmer error waiting to happen than an actual problem with E2 as a language, but the fact it errors in one place and not another is pretty stupid. |
It's mostly that locals aren't supposed to be accessed from events and it's kind of a hack that they're considered global if you do them at the top level. That assumption gets broken inside includes where the top level variables are no longer globals (pushed to level 1 so they don't interfere with the main script) |
E2cels stay losing 😔 |
I ran into a problem where an e2 that when isn't included works fine without warnings, but when included in a seperate e2 gives a nonsensical error.
The e2 in question:
The error when the file is included:
The text was updated successfully, but these errors were encountered: