-
-
Notifications
You must be signed in to change notification settings - Fork 374
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
Make NullToStrictStringFuncCallArgRector run without scope #4792
Conversation
8d8de86
to
1bf92d4
Compare
1bf92d4
to
bdf13cb
Compare
&$string | ||
): string { | ||
$innerPattern = $match['content']; | ||
$positionDelimiter = strpos((string) $innerPattern, ''); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
most ArrayDimFetch without context will go ErrorType, this should be skipped as before
@@ -477,10 +474,6 @@ private function processNullToStrictStringOnNodePosition( | |||
return null; | |||
} | |||
|
|||
if ($this->isAnErrorTypeFromParentScope($argValue, $scope)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should be reverted, most ArrayDimFetch without context will go ErrorType, and it wil cause huge string cast in legacy code
|
||
use Nette\Utils\Strings; | ||
|
||
final class SkipErrorType |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This fixture removal need to be reverted, per my comment before, ArrayDimFetch without context got ErrorType, it will make the rule unusable as it change the valid type string already, which mostly correct on regex check usage
@TomasVotruba I am reverting at #4793 |
Ref #4730