-
Notifications
You must be signed in to change notification settings - Fork 529
Merge constant types #1938
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
Merge constant types #1938
Conversation
2d99e27
to
a0a6a42
Compare
I don't have enough context for test change 98a960b |
I think the next step is figure out what to do with TypeSpecifier and filterBySpecifiedTypes so that it also fills nativeExpressionTypes correctly. Also - I'd love to see us to get rid of |
I'm excited for the next steps! |
I noticed that ScopeFactory::create seems covered by BC break...? The failing test of larastan was cause by this... |
Also, I'm reviewing MutatingScope.php on top of this PR and there are some inconsistencies in handling
I think these should also be cleaned up frist :) |
Thank you for the signposts. |
This pull request has been marked as ready for review. |
Sorry |
and webmozart-assert test too not sure why |
I have some idea - these language constants should stay the same, true is always true, but your refactoring probably made it not treated specially and thus from that point true is NeverType or something... |
6523bd7
to
1e49c11
Compare
Understood ConstFetch should be kept everywhere, even out of class |
This pull request has been marked as ready for review. |
Another todo: |
There are still some test failures :) |
About the BC break in ScopeFactory - yeah, it's annoying we can't change it as easily as this, I'm trying if Larastan can call it with less arguments here: larastan/larastan#1430 |
My plan to address ScopeFactory is:
|
f8137c1
to
834032a
Compare
I need this for an optimization so I'm gonna merge it now :) Thank you very much! |
Sitting back and watching the step-by-step cleanups is fun. This looks like another good one 😊 |
Would be nice to fix this one because it's now worse than before :) phpstan/phpstan#8034 |
Sorry for it. I had to go sleep:) |
Steps to fix
|
This Composer failure is weird: https://github.com/phpstan/phpstan/actions/runs/3359189577/jobs/5566968926
|
Refactoring mentioned in
#1919 (comment)
Now all types are merged with expressionTypes!
Now we are ready to start
phpstan/phpstan#8191