UPDATE Method.php, MethodTest.php

- Modify the RegEx, so that an annotation like `@method static $this myMethod()` is parsed correctly
- Write a Unittest for that usecase
This commit is contained in:
Christoph Harms-Ensink
2017-05-29 14:21:25 +02:00
committed by Jaap van Otterdijk
parent c14a4abfd7
commit e9454d844d
2 changed files with 32 additions and 4 deletions
+8 -4
View File
@@ -91,10 +91,14 @@ final class Method extends BaseTag implements Factory\StaticMethod
)?
# Return type
(?:
(
(?:[\w\|_\\\\]+)
# array notation
(?:\[\])*
(
(?:[\w\|_\\\\]*\$this[\w\|_\\\\]*)
|
(?:
(?:[\w\|_\\\\]+)
# array notation
(?:\[\])*
)
)?
\s+
)?