Skip to content

Commit ca86412

Browse files
committed
UninitializedPropertyRule should be always reported when checkUninitializedProperties is enabled
1 parent 59ccf55 commit ca86412

File tree

2 files changed

+10
-12
lines changed

2 files changed

+10
-12
lines changed

conf/config.level0.neon

-12
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
parameters:
22
customRulesetUsed: false
33

4-
conditionalTags:
5-
PHPStan\Rules\Properties\UninitializedPropertyRule:
6-
phpstan.rules.rule: %checkUninitializedProperties%
7-
84
rules:
95
- PHPStan\Rules\Api\ApiInstanceofRule
106
- PHPStan\Rules\Api\ApiInstanceofTypeRule
@@ -218,9 +214,6 @@ services:
218214
tags:
219215
- phpstan.rules.rule
220216

221-
-
222-
class: PHPStan\Rules\Properties\UninitializedPropertyRule
223-
224217
-
225218
class: PHPStan\Rules\Properties\WritingToReadOnlyPropertiesRule
226219
arguments:
@@ -250,11 +243,6 @@ services:
250243
tags:
251244
- phpstan.rules.rule
252245

253-
-
254-
class: PHPStan\Reflection\ConstructorsHelper
255-
arguments:
256-
additionalConstructors: %additionalConstructors%
257-
258246
-
259247
class: PHPStan\Rules\Keywords\RequireFileExistsRule
260248
arguments:

conf/config.neon

+10
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,8 @@ conditionalTags:
211211
phpstan.rules.rule: %exceptions.check.missingCheckedExceptionInThrows%
212212
PHPStan\Rules\Exceptions\MissingCheckedExceptionInPropertyHookThrowsRule:
213213
phpstan.rules.rule: %exceptions.check.missingCheckedExceptionInThrows%
214+
PHPStan\Rules\Properties\UninitializedPropertyRule:
215+
phpstan.rules.rule: %checkUninitializedProperties%
214216

215217
services:
216218
-
@@ -734,6 +736,11 @@ services:
734736
tags:
735737
- phpstan.broker.dynamicMethodReturnTypeExtension
736738

739+
-
740+
class: PHPStan\Reflection\ConstructorsHelper
741+
arguments:
742+
additionalConstructors: %additionalConstructors%
743+
737744
-
738745
class: PHPStan\Reflection\RequireExtension\RequireExtendsMethodsClassReflectionExtension
739746

@@ -1037,6 +1044,9 @@ services:
10371044
reportMagicProperties: %reportMagicProperties%
10381045
checkDynamicProperties: %checkDynamicProperties%
10391046

1047+
-
1048+
class: PHPStan\Rules\Properties\UninitializedPropertyRule
1049+
10401050
-
10411051
class: PHPStan\Rules\Properties\LazyReadWritePropertiesExtensionProvider
10421052

0 commit comments

Comments
 (0)