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

Infer mb_strtolower() result as string when encoding is specified #6912

Conversation

weirdan
Copy link
Collaborator

@weirdan weirdan commented Nov 14, 2021

mb_strtolower() may return characters we generally consider uppercase when it's given the encoding argument. This PR makes Psalm to err on the side of caution and treat the return type as string rather than lowercase-string in this case

Refs #6908

`mb_strtolower()` may return characters we generally consider uppercase
when it's given the encoding argument. This PR makes Psalm to err on the
side of caution and treat the return type as `string` rather than
`lowercase-string` in this case

Refs vimeo#6908
@weirdan weirdan added the release:fix The PR will be included in 'Fixes' section of the release notes label Nov 14, 2021
@weirdan weirdan requested a review from orklah November 14, 2021 02:03
@weirdan weirdan merged commit d61e31b into vimeo:master Nov 14, 2021
@weirdan weirdan deleted the mbstrotolower-produces-nonlowercase-strings-sometimes branch November 14, 2021 19:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release:fix The PR will be included in 'Fixes' section of the release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants