Skip to content

Commit 9edea31

Browse files
committed
Use exception-related rules in PHPStan
1 parent 43d0689 commit 9edea31

2 files changed

Lines changed: 9 additions & 0 deletions

File tree

phpstan.neon.dist

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ parameters:
33
implicitThrows: false
44
paths:
55
- src
6+
exceptions:
7+
check:
8+
missingCheckedExceptionInThrows: true
9+
tooWideThrowType: true
10+
uncheckedExceptionClasses:
11+
- LogicException
612
exceptionRules:
713
reportUnusedCatchesOfUncheckedExceptions: true
814
uncheckedExceptions:

phpstan.tests.neon.dist

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ parameters:
33
implicitThrows: false
44
paths:
55
- tests
6+
exceptions:
7+
check:
8+
tooWideThrowType: true
69

710
includes:
811
- vendor/phpstan/phpstan-strict-rules/rules.neon

0 commit comments

Comments
 (0)