Skip to content

Commit

Permalink
immediatelyCalledCallables: mention immediate closure call issue
Browse files Browse the repository at this point in the history
Resolves #210
  • Loading branch information
janedbal committed Feb 15, 2024
1 parent 3158b5e commit ab3fb7a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -484,6 +484,9 @@ class UserEditFacade
}
```

#### Limitations
- Immediatelly called closure (`(function(){})()` syntax) is not considered immediatelly-called even though it is ([related issue](https://github.com/shipmonk-rnd/phpstan-rules/issues/210))

### forbidCheckedExceptionInYieldingMethod
- Denies throwing [checked exception](https://phpstan.org/blog/bring-your-exceptions-under-control) within yielding methods as those exceptions are not throw upon method call, but when generator gets iterated.
- This behaviour cannot be easily reflected within PHPStan exception analysis and may cause [false negatives](https://phpstan.org/r/d07ac0f0-a49d-4f82-b1dd-1939058bbeed).
Expand Down

0 comments on commit ab3fb7a

Please sign in to comment.