Skip to content

Commit ba1d524

Browse files
authored
chore: handle intentional d() calls in static analysis (#10279)
* chore: handle intentional d() calls in static analysis * chore: update PHPStan baseline for intentional d() calls
1 parent 53fa63b commit ba1d524

2 files changed

Lines changed: 15 additions & 1 deletion

File tree

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# total 2 errors
2+
3+
parameters:
4+
ignoreErrors:
5+
-
6+
message: '#^Call to function d\(\) on a separate line has no effect\.$#'
7+
count: 1
8+
path: ../../system/Commands/Utilities/ConfigCheck.php
9+
10+
-
11+
message: '#^Call to function d\(\) on a separate line has no effect\.$#'
12+
count: 1
13+
path: ../../tests/system/CommonFunctionsTest.php

‎utils/phpstan-baseline/loader.neon‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# total 2010 errors
1+
# total 2012 errors
22

33
includes:
44
- argument.type.neon
@@ -10,6 +10,7 @@ includes:
1010
- codeigniter.superglobalAccessAssign.neon
1111
- deadCode.unreachable.neon
1212
- empty.notAllowed.neon
13+
- function.resultUnused.neon
1314
- method.alreadyNarrowedType.neon
1415
- method.childParameterType.neon
1516
- method.childReturnType.neon

0 commit comments

Comments
 (0)