Skip to content

Fix current_environment usages to use accessor instead of instance variable #173

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

Merged

Conversation

vinistock
Copy link
Contributor

This PR fixes a mistake made in #157

All of the visits inside the WithEnvironment module should use the current_environment method instead of accessing the instance variable directly. Otherwise, the "global" environment is not instantiated. See the included test for reproduction.

@kddnewton kddnewton merged commit 7034e68 into ruby-syntax-tree:main Oct 18, 2022
@vinistock vinistock deleted the vs/fix_with_environment_references branch October 18, 2022 14:43
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.

None yet

2 participants