added phpdoc to ParsingException#70
Conversation
|
Thanks |
|
|
||
| /** | ||
| * @param string $message | ||
| * @psalm-param array{text?: string, token?: string, line?: int, loc?: array, expected?: array} $details |
There was a problem hiding this comment.
loc might be documented with more details. Here is its structure:
jsonlint/src/Seld/JsonLint/Lexer.php
Line 77 in ff2aa54
There was a problem hiding this comment.
I will do a followup PR and also add phpstan, so we can verify the changes in the repo here.
There was a problem hiding this comment.
IIRC, PHPStan will also read the psalm-param annotation (it will just be less strict in the validation when it cannot understand the type)
There was a problem hiding this comment.
IIRC, PHPStan will also read the
psalm-paramannotation (it will just be less strict in the validation when it cannot understand the type)
yep correct.
with "and also add phpstan" I was refering to add a github action phpstan check in this repo here.
this Exception is likely beeing used from the caller side. therefore add some typing to reduce risk for errors
related to composer/composer#9120