Skip to content

Improve return type of token_name() and PhpToken::getTokenName()#3558

Merged
ondrejmirtes merged 1 commit intophpstan:1.12.xfrom
zonuexe:feature/improve-token_name-type
Oct 9, 2024
Merged

Improve return type of token_name() and PhpToken::getTokenName()#3558
ondrejmirtes merged 1 commit intophpstan:1.12.xfrom
zonuexe:feature/improve-token_name-type

Conversation

@zonuexe
Copy link
Contributor

@zonuexe zonuexe commented Oct 9, 2024

The return value of token_name() and PhpToken::getTokenName() is neither '' nor '0', so they can be typed more precisely.

refs phpstan/phpstan#11808, #3540

@ondrejmirtes ondrejmirtes merged commit 8dd41e9 into phpstan:1.12.x Oct 9, 2024
@ondrejmirtes
Copy link
Member

Thank you!

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