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

symbolWithContextSync causing Maximum call stack size exceeded #117

Open
jlchmura opened this issue May 17, 2024 · 2 comments
Open

symbolWithContextSync causing Maximum call stack size exceeded #117

jlchmura opened this issue May 17, 2024 · 2 comments

Comments

@jlchmura
Copy link

Mike,

The call to getAllSymbolsSync on line 303 was causing a RangeError in one of my symbol tables. Shouldn't it have localOnly set to true? Unless I misunderstand this use of this function, if we're looking for a symbol tied to a specific context, why would that symbol be in a non-local table anyway?

let symbols = this.getAllSymbolsSync(BaseSymbol);

@mike-lischke
Copy link
Owner

Yes, using only local symbols sounds reasonable. Did it solve your problem with that flag?

But even if it does, with deeply nested symbols this can always crash. Better would be to implement that as iteration (and exchange the duplicated local method code by a single implementation).

@jlchmura
Copy link
Author

Using local only did solve the problem. Though you're correct, I do need to look into an iteration-based implementation because I do have deeply nested symbols and this is bound to pop up somewhere else.

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