-
-
Notifications
You must be signed in to change notification settings - Fork 152
Description
Hi,
Nice piece of code. I think there is a problem when reading the @method annotation.
utils/src/Utils/ObjectHelpers.php
Line 78 in a828903
| self::parseFullDoc(new \ReflectionClass($class), '~^[ \t*]*@method[ \t]+(?:\S+[ \t]+)??(\w+)\(~m'), |
the format of the annotation can be of 2 type (static method or not) as documented here : https://doc.nette.org/en/contributing/coding-standard#toc-documentation-blocks-phpdoc
But the parsing is not correct if there is a "static" word instead of the return type.
Here is an example using the nette regex : https://sandbox.onlinephpfunctions.com/code/d381c1f6eefc80b3dd84292a514ff935eddf3e13
As you can see the array is only filed with the first method. If you remove the "static" word the array will be filled with the 2 methods name.
I hope i am clear enough.
Keep up the good work.