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

Clear iteration variable data during expression pruning #740

Merged
merged 2 commits into from
Jun 15, 2023

Conversation

TristonianJones
Copy link
Collaborator

This PR clears iteration variable data from expression tracking state during macro pruning.
The clearing of the iteration variable is based on the iteration variable name which could
potentially shadow an existing, but in the worst case, this would just cause a duplicate name
to be cleared more than once in a nested macro scope.

Closes #735

interpreter/prune.go Outdated Show resolved Hide resolved
@TristonianJones
Copy link
Collaborator Author

PTAL

@TristonianJones TristonianJones merged commit ecf04a5 into google:master Jun 15, 2023
@TristonianJones TristonianJones deleted the prune-clear-iter-vars branch June 15, 2023 23:18
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.

interpreter.PruneAst does not prune IterRange expression
2 participants