Merged
Conversation
e4d93c3 to
8da422a
Compare
8da422a to
a9cd107
Compare
TomasVotruba
commented
Nov 17, 2019
| * @param int $b | ||
| * @param int|void $c | ||
| */ | ||
| function someFunction(float|int $a, int $b, int|void $c) { |
Member
Author
There was a problem hiding this comment.
@nikic Hi, is int|void legal for paramter? I didn't find it excluded in: nikic/PHP-Parser@664c101
If not, what should be used here?
Member
Author
|
Agreed. I think Rector is taking care of this. Could you send failing test case to verify? |
TomasVotruba
added a commit
that referenced
this pull request
May 19, 2022
rectorphp/rector-src@30a53bf [DowngradePhp80] Add in arrow function in return support on DowngradeMatchToSwitchRector (#2331)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #2290
<?php class SomeClass { - /** - * @param array|int $number - * @return bool|float - */ - public function go($number) + public function go(array|int $number): bool|float { } }