Skip to content

Commit bd2cec1

Browse files
committed
Precise type for $matches from preg_match generally available, out of bleeding edge
1 parent c541ce1 commit bd2cec1

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

conf/bleedingEdge.neon

-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,6 @@ parameters:
5454
paramOutType: true
5555
pure: true
5656
checkParameterCastableToStringFunctions: true
57-
narrowPregMatches: true
5857
uselessReturnValue: true
5958
printfArrayParameters: true
6059
preciseMissingReturn: true

conf/config.neon

+10-5
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ parameters:
8989
paramOutType: false
9090
pure: false
9191
checkParameterCastableToStringFunctions: false
92-
narrowPregMatches: false
9392
uselessReturnValue: false
9493
printfArrayParameters: false
9594
preciseMissingReturn: false
@@ -290,10 +289,6 @@ conditionalTags:
290289
phpstan.parser.richParserNodeVisitor: %featureToggles.curlSetOptTypes%
291290
PHPStan\Parser\TypeTraverserInstanceofVisitor:
292291
phpstan.parser.richParserNodeVisitor: %featureToggles.instanceofType%
293-
PHPStan\Type\Php\PregMatchTypeSpecifyingExtension:
294-
phpstan.typeSpecifier.functionTypeSpecifyingExtension: %featureToggles.narrowPregMatches%
295-
PHPStan\Type\Php\PregMatchParameterOutTypeExtension:
296-
phpstan.functionParameterOutTypeExtension: %featureToggles.narrowPregMatches%
297292

298293
services:
299294
-
@@ -1491,6 +1486,16 @@ services:
14911486
-
14921487
class: PHPStan\Type\Php\PregMatchTypeSpecifyingExtension
14931488

1489+
-
1490+
class: PHPStan\Type\Php\PregMatchTypeSpecifyingExtension
1491+
tags:
1492+
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
1493+
1494+
-
1495+
class: PHPStan\Type\Php\PregMatchParameterOutTypeExtension
1496+
tags:
1497+
- phpstan.functionParameterOutTypeExtension
1498+
14941499
-
14951500
class: PHPStan\Type\Php\PregMatchParameterOutTypeExtension
14961501

conf/parametersSchema.neon

-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,6 @@ parametersSchema:
8484
paramOutType: bool()
8585
pure: bool()
8686
checkParameterCastableToStringFunctions: bool()
87-
narrowPregMatches: bool()
8887
uselessReturnValue: bool()
8988
printfArrayParameters: bool()
9089
preciseMissingReturn: bool()

0 commit comments

Comments
 (0)