-
-
Notifications
You must be signed in to change notification settings - Fork 861
/
phpstan.neon
88 lines (85 loc) · 3.88 KB
/
phpstan.neon
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
includes:
- ../vendor/phpstan/phpstan-deprecation-rules/rules.neon
- ../vendor/phpstan/phpstan-php-parser/extension.neon
- ../vendor/phpstan/phpstan-phpunit/extension.neon
- ../vendor/phpstan/phpstan-phpunit/rules.neon
- ../vendor/phpstan/phpstan-strict-rules/rules.neon
- ../conf/bleedingEdge.neon
parameters:
bootstrap: %rootDir%/tests/phpstan-bootstrap.php
excludes_analyse:
- %rootDir%/src/Reflection/SignatureMap/functionMap.php
- %rootDir%/src/Reflection/SignatureMap/functionMetadata.php
- %rootDir%/tests/*/data/*
- %rootDir%/tests/PHPStan/Analyser/traits/*
- %rootDir%/tests/notAutoloaded/*
- %rootDir%/tests/PHPStan/Generics/functions.php
featureToggles:
missingClosureNativeReturnTypehintRule: true
ignoreErrors:
- '#^Strict comparison using === between PhpParser\\Node\\Expr\\ArrayItem and null will always evaluate to false\.$#'
- '#^Dynamic call to static method PHPUnit\\Framework\\\S+\(\)\.$#'
- '#^Only numeric types are allowed in (pre|post)-(de|in)crement, bool\|float\|int\|string\|null given\.$#'
- '#should be contravariant with parameter \$node \(PhpParser\\Node\) of method PHPStan\\Rules\\Rule::processNode\(\)$#'
- '#^Parameter .* of method PHPStan\\Command\\ErrorsConsoleStyle::.*\(\) should be contravariant with parameter .* of method Symfony\\Component\\Console\\Style\\(StyleInterface|SymfonyStyle)::.*()$#'
- '#Variable property access on PhpParser\\Node#'
-
message: '#Variable method call on PHPStan\\Reflection\\ClassReflection\.#'
path: %rootDir%/src/PhpDoc/PhpDocBlock.php
-
message: '#Variable static method call on PHPStan\\PhpDoc\\PhpDocBlock\.#'
path: %rootDir%/src/PhpDoc/PhpDocBlock.php
-
message: '#Anonymous function has an unused use \$container\.#'
path: %rootDir%/src/Command/CommandHelper.php
-
message: '#Access to constant EXTENSIONS on an unknown class PHPStan\\ExtensionInstaller\\GeneratedConfig\.#'
path: %rootDir%/src/Command/CommandHelper.php
-
message: '#Variable (?:static )?method call#'
path: %rootDir%/src/DependencyInjection/ParametersSchemaExtension.php
-
message: '#Fetching class constant class of deprecated class DeprecatedAnnotations\\DeprecatedFoo.#'
path: %rootDir%/tests/PHPStan/Reflection/Annotations/DeprecatedAnnotationsTest.php
-
message: '#Fetching class constant class of deprecated class DeprecatedAnnotations\\DeprecatedWithMultipleTags.#'
path: %rootDir%/tests/PHPStan/Reflection/Annotations/DeprecatedAnnotationsTest.php
-
message: "#^Call to function method_exists\\(\\) with ReflectionProperty and '(?:hasType|getType)' will always evaluate to true\\.$#"
path: %rootDir%/src/Reflection/Php/PhpClassReflectionExtension.php
-
message: '#^Constant SOME_CONSTANT_IN_AUTOLOAD_FILE not found\.$#'
path: %rootDir%/tests/PHPStan/Command/AnalyseCommandTest.php
-
message: '#^Fetching class constant PREVENT_MERGING of deprecated class Nette\\DI\\Config\\Helpers\.$#'
path: ../src/DependencyInjection/NeonAdapter.php
reportStaticMethodSignatures: true
reportUnmatchedIgnoredErrors: false
tmpDir: %rootDir%/tmp
services:
-
class: PHPStan\Build\ServiceLocatorDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicMethodReturnTypeExtension
-
class: PHPStan\Internal\ContainerDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicMethodReturnTypeExtension
-
class: PHPStan\Internal\UnionTypeGetInternalDynamicReturnTypeExtension
tags:
- phpstan.broker.dynamicMethodReturnTypeExtension
scopeIsInClass:
class: PHPStan\Internal\ScopeIsInClassTypeSpecifyingExtension
arguments:
isInMethodName: isInClass
removeNullMethodName: getClassReflection
tags:
- phpstan.typeSpecifier.methodTypeSpecifyingExtension
scopeIsInTrait:
class: PHPStan\Internal\ScopeIsInClassTypeSpecifyingExtension
arguments:
isInMethodName: isInTrait
removeNullMethodName: getTraitReflection
tags:
- phpstan.typeSpecifier.methodTypeSpecifyingExtension