-
Notifications
You must be signed in to change notification settings - Fork 230
DocParser: Improve private typehints #332
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
c0ed4b2 to
0e636eb
Compare
This comment has been minimized.
This comment has been minimized.
It makes the code more readable and IDE less confused.
0e636eb to
1a8a646
Compare
|
Thanks @jkufner ! |
| * @return int|null | ||
| */ | ||
| private function findInitialTokenPosition($input) | ||
| private function findInitialTokenPosition($input): ?int |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if you add the return type, why not adding the argument type too ?
| * Generates a new syntax error. | ||
| * | ||
| * @param string $expected Expected string. | ||
| * @param array|null $token Optional token. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the descriptions don't really provide any value here, and the types are not specified through typehints
Release [1.10.4](https://github.com/doctrine/annotations/milestone/25) 1.10.4 ====== - Total issues resolved: **0** - Total pull requests resolved: **8** - Total contributors: **5** - [347: Add support for the new PHP 8 tokens for use statements](doctrine#347) thanks to @stof - [345: Remove calls to TestCase::at()](doctrine#345) thanks to @greg0ire - [343: Allow using PHPUnit 9.3](doctrine#343) thanks to @greg0ire Improvement ----------- - [342: Upgrade phpunit](doctrine#342) thanks to @greg0ire - [332: DocParser: Improve private typehints](doctrine#332) thanks to @jkufner bug --- - [341: Make type in phpdoc resolvable](doctrine#341) thanks to @greg0ire Documentation ------------- - [338: update annotation IDE annotation with current links](doctrine#338) thanks to @Haehnchen Documentation,Improvement ------------------------- - [337: Replace "blacklist" terminology with "ignore"](doctrine#337) thanks to @albe
Release [1.10.4](https://github.com/doctrine/annotations/milestone/25) 1.10.4 ====== - Total issues resolved: **0** - Total pull requests resolved: **8** - Total contributors: **5** - [347: Add support for the new PHP 8 tokens for use statements](doctrine#347) thanks to @stof - [345: Remove calls to TestCase::at()](doctrine#345) thanks to @greg0ire - [343: Allow using PHPUnit 9.3](doctrine#343) thanks to @greg0ire Improvement ----------- - [342: Upgrade phpunit](doctrine#342) thanks to @greg0ire - [332: DocParser: Improve private typehints](doctrine#332) thanks to @jkufner bug --- - [341: Make type in phpdoc resolvable](doctrine#341) thanks to @greg0ire Documentation ------------- - [338: update annotation IDE annotation with current links](doctrine#338) thanks to @Haehnchen Documentation,Improvement ------------------------- - [337: Replace "blacklist" terminology with "ignore"](doctrine#337) thanks to @albe # gpg: Signature made Tue Aug 11 20:55:32 2020 # gpg: using DSA key 1BEDEE0A820BC30D858F9F0C2C3A645671828132 # gpg: Can't check signature: No public key # Conflicts: # composer.json # lib/Doctrine/Common/Annotations/Annotation/Attributes.php # lib/Doctrine/Common/Annotations/DocParser.php # tests/Doctrine/Tests/Common/Annotations/AbstractReaderTest.php # tests/Doctrine/Tests/Common/Annotations/AnnotationReaderTest.php # tests/Doctrine/Tests/Common/Annotations/DocParserTest.php # tests/Doctrine/Tests/Common/Annotations/FileCacheReaderTest.php # tests/Doctrine/Tests/Common/Annotations/SimpleAnnotationReaderTest.php # tests/Doctrine/Tests/Common/Annotations/Ticket/DCOM55Test.php
None of these changes should change any behavior.