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

[PHP81] Skip after is_string on object call on NullToStrictStringFuncCallArgRector #5572

Merged
merged 2 commits into from
Feb 7, 2024

Conversation

samsonasik
Copy link
Member

@samsonasik
Copy link
Member Author

Fixed 🎉 /cc @OskarStark


final class SkipAfterIsStringOnObjectCall
{
public ?string $stringNull = 'foo';
Copy link
Contributor

Choose a reason for hiding this comment

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

does this also work with a method instead of a property?

Copy link
Member Author

@samsonasik samsonasik Feb 7, 2024

Choose a reason for hiding this comment

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

should be work if native type defined, the NullToStrictStringFuncCallArgRector is to work with safe change,

  • with @param string, it means already string, to avoid too many change,
  • with native type, it means already string as well.

Copy link
Contributor

@staabm staabm Feb 7, 2024

Choose a reason for hiding this comment

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

@OskarStark you can try on https://getrector.com/demo whether you find another case :)

shortly after a PR is merged the demo is updated

Copy link
Contributor

Choose a reason for hiding this comment

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

Thanks for the info

@samsonasik
Copy link
Member Author

All checks have passed 🎉 @TomasVotruba I am merging it;)

@samsonasik samsonasik merged commit af4d3db into main Feb 7, 2024
41 checks passed
@samsonasik samsonasik deleted the after-istr-stirng branch February 7, 2024 10:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants