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

Track references on global variables #5122

Merged
merged 3 commits into from Jan 28, 2021
Merged

Conversation

joehoyle
Copy link
Contributor

@joehoyle joehoyle commented Jan 28, 2021

Add global type references to the type map, and fix up unused detection on global variables. To do this I had to also register the globals in the var maps when you do global $x. I think this makes sense -- in doing so I also had to add the Node references to satisfy the unused variable detection.

Add global type references to the type map, and fix up unused detection on global variables.
@muglug muglug merged commit a3dcc52 into vimeo:master Jan 28, 2021
@muglug
Copy link
Collaborator

muglug commented Jan 28, 2021

Thanks, looks good!

danog pushed a commit to danog/psalm that referenced this pull request Jan 29, 2021
* Track references on global variables

Add global type references to the type map, and fix up unused detection on global variables.

* Add null assertions

* PHPCS
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