52
52
use PHPStan \Rules \Generics \InterfaceAncestorsRule ;
53
53
use PHPStan \Rules \Generics \InterfaceTemplateTypeRule ;
54
54
use PHPStan \Rules \Generics \MethodSignatureVarianceRule ;
55
+ use PHPStan \Rules \Generics \MethodTagTemplateTypeCheck ;
56
+ use PHPStan \Rules \Generics \MethodTagTemplateTypeRule ;
55
57
use PHPStan \Rules \Generics \MethodTemplateTypeRule ;
56
58
use PHPStan \Rules \Generics \TemplateTypeCheck ;
57
59
use PHPStan \Rules \Generics \TraitTemplateTypeRule ;
@@ -178,6 +180,7 @@ private function getRuleRegistry(Container $container): RuleRegistry
178
180
$ localTypeAliasesCheck = $ container ->getByType (LocalTypeAliasesCheck::class);
179
181
$ phpClassReflectionExtension = $ container ->getByType (PhpClassReflectionExtension::class);
180
182
$ genericCallableRuleHelper = $ container ->getByType (GenericCallableRuleHelper::class);
183
+ $ methodTagTemplateTypeCheck = $ container ->getByType (MethodTagTemplateTypeCheck::class);
181
184
182
185
$ rules = [
183
186
// level 0
@@ -201,6 +204,7 @@ private function getRuleRegistry(Container $container): RuleRegistry
201
204
new InterfaceAncestorsRule ($ genericAncestorsCheck , $ crossCheckInterfacesHelper ),
202
205
new InterfaceTemplateTypeRule ($ templateTypeCheck ),
203
206
new MethodTemplateTypeRule ($ fileTypeMapper , $ templateTypeCheck ),
207
+ new MethodTagTemplateTypeRule ($ methodTagTemplateTypeCheck ),
204
208
new MethodSignatureVarianceRule ($ varianceCheck ),
205
209
new TraitTemplateTypeRule ($ fileTypeMapper , $ templateTypeCheck ),
206
210
new IncompatiblePhpDocTypeRule ($ fileTypeMapper , $ genericObjectTypeCheck , $ unresolvableTypeHelper , $ genericCallableRuleHelper ),
0 commit comments