NewExceptionsFromToString: 2 bugfixes + 1 enhancement by jrfnl · Pull Request #880 · PHPCompatibility/PHPCompatibility
added 3 commits
August 21, 2019 19:48This property is not intended to be set via a custom ruleset, so the property should never have been `public`.
When an exception is thrown within a `try/catch` block, ignore it. This changes the sniff, in that previously only one error per method would be thrown. Now, an error will be thrown for each `throw` tag not in a `try/catch`. Fixes 863
This adds an additional check based on the docblock to attempt to catch exceptions thrown indirectly from this method. If the docblock indicates that the function may throw an exception, trust it. The additional check will only be run if search for the `throw` keyword didn't yield any errors. Fixes 863
jrfnl
mentioned this pull request
wimg approved these changes Aug 28, 2019
jrfnl
mentioned this pull request
40 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters