Skip to content

Conversation

@NotHyper-474
Copy link

@NotHyper-474 NotHyper-474 commented Nov 30, 2025

The merge of #247 introduced a bug where trying to access either of those classes in a static function would cause a missing import error, this is because it causes the static interpreter's variables to get reset to HScript's defaults.

The fix here involves removing the definition from the Interp's constructor and instead making those default imports.
It should be noted that this would not fix the issue for static local functions because those lose their context, which #209 fixes.

@NotHyper-474 NotHyper-474 changed the title [FIX] Math and Std not being avaliable in a static context [FIX] Math and Std not being avaliable for static functions Nov 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant