Skip to content

Conversation

staabm
Copy link
Contributor

@staabm staabm commented Jun 16, 2022

@staabm staabm marked this pull request as ready for review June 16, 2022 07:27
@@ -78,6 +78,10 @@ public function isSubTypeOf(Type $otherType): TrinaryLogic

public function isAcceptedBy(Type $acceptingType, bool $strictTypes): TrinaryLogic
{
if ($acceptingType->isNonEmptyString()->yes()) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I tried adding this case in isSubTypeOf() instead, but this made other tests fail. therefore the fix looks like it is right now.

@ondrejmirtes ondrejmirtes merged commit 6696f45 into phpstan:1.7.x Jun 16, 2022
@ondrejmirtes
Copy link
Member

Thank you!

@staabm staabm deleted the numeric-vs-non-empty branch June 18, 2022 06:24
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.

numeric-string is non considered non-empty-string
2 participants