|
50 | 50 | <property name="maxPadding" value="1"/> |
51 | 51 | </properties> |
52 | 52 | </rule> |
53 | | - <rule ref="Generic.Functions.CallTimePassByReference"/> |
54 | 53 | <rule ref="Generic.Functions.OpeningFunctionBraceBsdAllman"/> |
55 | 54 | <rule ref="Generic.NamingConventions.ConstructorName"/> |
56 | 55 | <rule ref="Generic.PHP.BacktickOperator"/> |
|
63 | 62 | <rule ref="Generic.PHP.DisallowShortOpenTag"/> |
64 | 63 | <rule ref="Generic.PHP.ForbiddenFunctions"> |
65 | 64 | <properties> |
66 | | - <property |
67 | | - name="forbiddenFunctions" |
68 | | - type="array" |
69 | | - value=" |
70 | | - mt_rand=>rand, |
71 | | - sizeof=>count, |
72 | | - delete=>unset, |
73 | | - print=>echo, |
74 | | - join=>implode, |
75 | | - split=>explode, |
76 | | - is_null=>null, |
77 | | - create_function=>null, |
78 | | - key_exists=>array_key_exists, |
79 | | - floatval=>null, |
80 | | - boolval=>null, |
81 | | - intval=>null, |
82 | | - strval=>null, |
83 | | - settype=>null, |
84 | | - exit=>null, |
85 | | - reset=>array_key_first |
86 | | - " |
87 | | - /> |
| 65 | + <property name="forbiddenFunctions" type="array"> |
| 66 | + <element key="mt_rand" value="rand"/> |
| 67 | + <element key="sizeof" value="count"/> |
| 68 | + <element key="delete" value="unset"/> |
| 69 | + <element key="print" value="echo"/> |
| 70 | + <element key="join" value="implode"/> |
| 71 | + <element key="split" value="explode"/> |
| 72 | + <element key="is_null" value="null"/> |
| 73 | + <element key="create_function" value="null"/> |
| 74 | + <element key="key_exists" value="array_key_exists"/> |
| 75 | + <element key="floatval" value="null"/> |
| 76 | + <element key="boolval" value="null"/> |
| 77 | + <element key="intval" value="null"/> |
| 78 | + <element key="strval" value="null"/> |
| 79 | + <element key="settype" value="null"/> |
| 80 | + <element key="exit" value="null"/> |
| 81 | + <element key="reset" value="array_key_first"/> |
| 82 | + </property> |
88 | 83 | </properties> |
89 | 84 | </rule> |
90 | 85 | <rule ref="Generic.Strings.UnnecessaryStringConcat"> |
|
93 | 88 | </properties> |
94 | 89 | </rule> |
95 | 90 | <rule ref="Generic.VersionControl.GitMergeConflict"/> |
| 91 | + <rule ref="Generic.WhiteSpace.LanguageConstructSpacing"/> |
96 | 92 | <rule ref="Generic.WhiteSpace.IncrementDecrementSpacing"/> |
97 | 93 | <rule ref="Generic.WhiteSpace.ScopeIndent"> |
98 | 94 | <properties> |
|
222 | 218 | <property name="spacing" value="1"/> |
223 | 219 | </properties> |
224 | 220 | </rule> |
225 | | - <rule ref="Squiz.WhiteSpace.LanguageConstructSpacing"/> |
226 | 221 | <rule ref="Squiz.WhiteSpace.LogicalOperatorSpacing"/> |
227 | 222 | <rule ref="Squiz.WhiteSpace.MemberVarSpacing"/> |
228 | 223 | <rule ref="Squiz.WhiteSpace.ObjectOperatorSpacing"> |
|
294 | 289 | <rule ref="SlevomatCodingStandard.Commenting.UselessInheritDocComment"/> |
295 | 290 | <rule ref="SlevomatCodingStandard.Commenting.ForbiddenComments"> |
296 | 291 | <properties> |
297 | | - <property name="forbiddenCommentPatterns" type="array" value="~^[a-zA-Z0-9]+ constructor.?$~,~PhpStorm~,~^[GS]et [a-zA-Z0-9]+$~"/> |
| 292 | + <property name="forbiddenCommentPatterns" type="array"> |
| 293 | + <element value="~^[a-zA-Z0-9]+ constructor.?$~"/> |
| 294 | + <element value="~PhpStorm~"/> |
| 295 | + <element value="~^[GS]et [a-zA-Z0-9]+$~"/> |
| 296 | + </property> |
298 | 297 | </properties> |
299 | 298 | </rule> |
300 | 299 | <rule ref="SlevomatCodingStandard.Commenting.ForbiddenAnnotations"> |
301 | 300 | <properties> |
302 | | - <property name="forbiddenAnnotations" type="array" value="@author,@created,@version,@package,@copyright,@license,@since,@link,@group,@expectedException" /> |
| 301 | + <property name="forbiddenAnnotations" type="array"> |
| 302 | + <element value="@author"/> |
| 303 | + <element value="@created"/> |
| 304 | + <element value="@version"/> |
| 305 | + <element value="@package"/> |
| 306 | + <element value="@copyright"/> |
| 307 | + <element value="@license"/> |
| 308 | + <element value="@since"/> |
| 309 | + <element value="@link"/> |
| 310 | + <element value="@group"/> |
| 311 | + <element value="@expectedException"/> |
| 312 | + </property> |
303 | 313 | </properties> |
304 | 314 | </rule> |
305 | 315 | <rule ref="SlevomatCodingStandard.ControlStructures.AssignmentInCondition"/> |
|
374 | 384 | <property name="declareOnFirstLine" value="true"/> |
375 | 385 | </properties> |
376 | 386 | </rule> |
| 387 | + <rule ref="SlevomatCodingStandard.TypeHints.DNFTypeHintFormat" /> |
377 | 388 | <rule ref="SlevomatCodingStandard.TypeHints.NullableTypeForNullDefaultValue" /> |
378 | 389 | <rule ref="SlevomatCodingStandard.TypeHints.NullTypeHintOnLastPosition" /> |
379 | | - <rule ref="SlevomatCodingStandard.TypeHints.UnionTypeHintFormat" /> |
380 | 390 | <rule ref="SlevomatCodingStandard.TypeHints.UselessConstantTypeHint" /> |
381 | 391 | <rule ref="SlevomatCodingStandard.TypeHints.PropertyTypeHint"> |
382 | 392 | <properties> |
383 | 393 | <property name="enableNativeTypeHint" value="true"/> |
384 | | - <property name="traversableTypeHints" type="array" value=" |
385 | | - Generator, |
386 | | - Traversable, |
387 | | - Doctrine\Common\Collections\Collection |
388 | | - "/> |
| 394 | + <property name="traversableTypeHints" type="array"> |
| 395 | + <element value="Generator"/> |
| 396 | + <element value="Traversable"/> |
| 397 | + <element value="Doctrine\Common\Collections\Collection"/> |
| 398 | + </property> |
389 | 399 | </properties> |
390 | 400 | </rule> |
391 | 401 |
|
392 | 402 | <rule ref="SlevomatCodingStandard.TypeHints.ParameterTypeHint"> |
393 | 403 | <properties> |
394 | | - <property name="traversableTypeHints" type="array" value=" |
395 | | - Generator, |
396 | | - Traversable, |
397 | | - Doctrine\Common\Collections\Collection |
398 | | - "/> |
| 404 | + <property name="traversableTypeHints" type="array"> |
| 405 | + <element value="Generator"/> |
| 406 | + <element value="Traversable"/> |
| 407 | + <element value="Doctrine\Common\Collections\Collection"/> |
| 408 | + </property> |
399 | 409 | </properties> |
400 | 410 | <exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingTraversableTypeHintSpecification"/><!-- this has problems with vendor libs, PHPStan checks this much more reliably --> |
401 | 411 | <exclude name="SlevomatCodingStandard.TypeHints.ParameterTypeHint.MissingNativeTypeHint"/><!-- this has problems with vendor libs, PHPStan checks this much more reliably --> |
402 | 412 | </rule> |
403 | 413 | <rule ref="SlevomatCodingStandard.TypeHints.ReturnTypeHint"> |
404 | 414 | <properties> |
405 | | - <property name="traversableTypeHints" type="array" value=" |
406 | | - Generator, |
407 | | - Traversable, |
408 | | - Doctrine\Common\Collections\Collection |
409 | | - "/> |
| 415 | + <property name="traversableTypeHints" type="array"> |
| 416 | + <element value="Generator"/> |
| 417 | + <element value="Traversable"/> |
| 418 | + <element value="Doctrine\Common\Collections\Collection"/> |
| 419 | + </property> |
410 | 420 | </properties> |
411 | 421 | <exclude name="SlevomatCodingStandard.TypeHints.ReturnTypeHint.MissingTraversableTypeHintSpecification"/><!-- this has problems with vendor libs, PHPStan checks this much more reliably --> |
412 | 422 | </rule> |
|
0 commit comments