Skip to content

Commit 5f316aa

Browse files
committed
more autowire
1 parent c14dee1 commit 5f316aa

12 files changed

+22
-54
lines changed

conf/config.neon

Lines changed: 0 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1232,60 +1232,6 @@ services:
12321232
tags:
12331233
- phpstan.dynamicFunctionThrowTypeExtension
12341234

1235-
-
1236-
class: PHPStan\Type\Php\JsonThrowTypeExtension
1237-
tags:
1238-
- phpstan.dynamicFunctionThrowTypeExtension
1239-
1240-
-
1241-
class: PHPStan\Type\Php\ParseStrParameterOutTypeExtension
1242-
tags:
1243-
- phpstan.functionParameterOutTypeExtension
1244-
1245-
-
1246-
class: PHPStan\Type\Php\PregMatchTypeSpecifyingExtension
1247-
tags:
1248-
- phpstan.typeSpecifier.functionTypeSpecifyingExtension
1249-
1250-
-
1251-
class: PHPStan\Type\Php\PregMatchParameterOutTypeExtension
1252-
tags:
1253-
- phpstan.functionParameterOutTypeExtension
1254-
1255-
-
1256-
class: PHPStan\Type\Php\PregReplaceCallbackClosureTypeExtension
1257-
tags:
1258-
- phpstan.functionParameterClosureTypeExtension
1259-
1260-
-
1261-
class: PHPStan\Type\Php\RegexArrayShapeMatcher
1262-
1263-
-
1264-
class: PHPStan\Type\Regex\RegexGroupParser
1265-
1266-
-
1267-
class: PHPStan\Type\Regex\RegexExpressionHelper
1268-
1269-
-
1270-
class: PHPStan\Type\Php\ReflectionClassConstructorThrowTypeExtension
1271-
tags:
1272-
- phpstan.dynamicStaticMethodThrowTypeExtension
1273-
1274-
-
1275-
class: PHPStan\Type\Php\ReflectionFunctionConstructorThrowTypeExtension
1276-
tags:
1277-
- phpstan.dynamicStaticMethodThrowTypeExtension
1278-
1279-
-
1280-
class: PHPStan\Type\Php\ReflectionMethodConstructorThrowTypeExtension
1281-
tags:
1282-
- phpstan.dynamicStaticMethodThrowTypeExtension
1283-
1284-
-
1285-
class: PHPStan\Type\Php\ReflectionPropertyConstructorThrowTypeExtension
1286-
tags:
1287-
- phpstan.dynamicStaticMethodThrowTypeExtension
1288-
12891235
-
12901236
class: PHPStan\Type\Php\VersionCompareFunctionDynamicReturnTypeExtension
12911237
arguments:

src/Type/Php/JsonThrowTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use PhpParser\Node\Expr\FuncCall;
66
use PhpParser\Node\Name;
77
use PHPStan\Analyser\Scope;
8+
use PHPStan\DependencyInjection\AutowiredService;
89
use PHPStan\Reflection\FunctionReflection;
910
use PHPStan\Reflection\ReflectionProvider;
1011
use PHPStan\Type\BitwiseFlagHelper;
@@ -13,6 +14,7 @@
1314
use PHPStan\Type\Type;
1415
use function in_array;
1516

17+
#[AutowiredService]
1618
final class JsonThrowTypeExtension implements DynamicFunctionThrowTypeExtension
1719
{
1820

src/Type/Php/ParseStrParameterOutTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PhpParser\Node\Expr\FuncCall;
66
use PHPStan\Analyser\Scope;
7+
use PHPStan\DependencyInjection\AutowiredService;
78
use PHPStan\Reflection\FunctionReflection;
89
use PHPStan\Reflection\ParameterReflection;
910
use PHPStan\Type\Accessory\AccessoryLowercaseStringType;
@@ -20,6 +21,7 @@
2021
use function in_array;
2122
use function strtolower;
2223

24+
#[AutowiredService]
2325
final class ParseStrParameterOutTypeExtension implements FunctionParameterOutTypeExtension
2426
{
2527

src/Type/Php/PregMatchParameterOutTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PhpParser\Node\Expr\FuncCall;
66
use PHPStan\Analyser\Scope;
7+
use PHPStan\DependencyInjection\AutowiredService;
78
use PHPStan\Reflection\FunctionReflection;
89
use PHPStan\Reflection\ParameterReflection;
910
use PHPStan\TrinaryLogic;
@@ -12,6 +13,7 @@
1213
use function in_array;
1314
use function strtolower;
1415

16+
#[AutowiredService]
1517
final class PregMatchParameterOutTypeExtension implements FunctionParameterOutTypeExtension
1618
{
1719

src/Type/Php/PregMatchTypeSpecifyingExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,14 @@
88
use PHPStan\Analyser\TypeSpecifier;
99
use PHPStan\Analyser\TypeSpecifierAwareExtension;
1010
use PHPStan\Analyser\TypeSpecifierContext;
11+
use PHPStan\DependencyInjection\AutowiredService;
1112
use PHPStan\Reflection\FunctionReflection;
1213
use PHPStan\TrinaryLogic;
1314
use PHPStan\Type\FunctionTypeSpecifyingExtension;
1415
use function in_array;
1516
use function strtolower;
1617

18+
#[AutowiredService]
1719
final class PregMatchTypeSpecifyingExtension implements FunctionTypeSpecifyingExtension, TypeSpecifierAwareExtension
1820
{
1921

src/Type/Php/ReflectionClassConstructorThrowTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PhpParser\Node\Expr\StaticCall;
66
use PHPStan\Analyser\Scope;
7+
use PHPStan\DependencyInjection\AutowiredService;
78
use PHPStan\Reflection\MethodReflection;
89
use PHPStan\Type\ClassStringType;
910
use PHPStan\Type\DynamicStaticMethodThrowTypeExtension;
@@ -13,6 +14,7 @@
1314
use ReflectionClass;
1415
use function count;
1516

17+
#[AutowiredService]
1618
final class ReflectionClassConstructorThrowTypeExtension implements DynamicStaticMethodThrowTypeExtension
1719
{
1820

src/Type/Php/ReflectionFunctionConstructorThrowTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
use PhpParser\Node\Expr\StaticCall;
66
use PhpParser\Node\Name;
77
use PHPStan\Analyser\Scope;
8+
use PHPStan\DependencyInjection\AutowiredService;
89
use PHPStan\Reflection\MethodReflection;
910
use PHPStan\Reflection\ReflectionProvider;
1011
use PHPStan\Type\DynamicStaticMethodThrowTypeExtension;
@@ -14,6 +15,7 @@
1415
use ReflectionFunction;
1516
use function count;
1617

18+
#[AutowiredService]
1719
final class ReflectionFunctionConstructorThrowTypeExtension implements DynamicStaticMethodThrowTypeExtension
1820
{
1921

src/Type/Php/ReflectionMethodConstructorThrowTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PhpParser\Node\Expr\StaticCall;
66
use PHPStan\Analyser\Scope;
7+
use PHPStan\DependencyInjection\AutowiredService;
78
use PHPStan\Reflection\MethodReflection;
89
use PHPStan\Reflection\ReflectionProvider;
910
use PHPStan\Type\Constant\ConstantStringType;
@@ -16,6 +17,7 @@
1617
use ReflectionMethod;
1718
use function count;
1819

20+
#[AutowiredService]
1921
final class ReflectionMethodConstructorThrowTypeExtension implements DynamicStaticMethodThrowTypeExtension
2022
{
2123

src/Type/Php/ReflectionPropertyConstructorThrowTypeExtension.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PhpParser\Node\Expr\StaticCall;
66
use PHPStan\Analyser\Scope;
7+
use PHPStan\DependencyInjection\AutowiredService;
78
use PHPStan\Reflection\MethodReflection;
89
use PHPStan\Reflection\ReflectionProvider;
910
use PHPStan\Type\DynamicStaticMethodThrowTypeExtension;
@@ -13,6 +14,7 @@
1314
use ReflectionProperty;
1415
use function count;
1516

17+
#[AutowiredService]
1618
final class ReflectionPropertyConstructorThrowTypeExtension implements DynamicStaticMethodThrowTypeExtension
1719
{
1820

src/Type/Php/RegexArrayShapeMatcher.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
use PhpParser\Node\Expr;
66
use PHPStan\Analyser\Scope;
7+
use PHPStan\DependencyInjection\AutowiredService;
78
use PHPStan\Php\PhpVersion;
89
use PHPStan\TrinaryLogic;
910
use PHPStan\Type\Accessory\AccessoryArrayListType;
@@ -32,6 +33,7 @@
3233
/**
3334
* @api
3435
*/
36+
#[AutowiredService]
3537
final class RegexArrayShapeMatcher
3638
{
3739

0 commit comments

Comments
 (0)