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

Check root return in ReturnTypeFromReturnNewRector #6102

Merged
merged 2 commits into from
Jul 2, 2024

Conversation

TomasVotruba
Copy link
Member

No description provided.

@TomasVotruba TomasVotruba force-pushed the tv-split-nullable-and-return branch from 08a6b21 to 541ceeb Compare July 2, 2024 10:08
return new FirstResponse();
}

return new SecondResponse();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

new fixture for else syntax seems needed:

        if (mt_rand(0, 1)) {
            return new FirstResponse();
        } else {
            return new SecondResponse();
       }

SilentVoidResolver->hasSilentVoid($node) should can detect that, if you want to consider...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll look into it in next iteration

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@TomasVotruba TomasVotruba merged commit f09e1bd into main Jul 2, 2024
33 checks passed
@TomasVotruba TomasVotruba deleted the tv-split-nullable-and-return branch July 2, 2024 13:52
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.

2 participants