1 | <?php |
||
16 | class DefinitionLexer |
||
17 | { |
||
18 | const T_OPEN_OPTION_SYMBOL = "T_OPEN_OPTION_SYMBOL"; |
||
19 | const T_CLOSE_OPTION_SYMBOL = "T_CLOSE_OPTION_SYMBOL"; |
||
20 | const T_OPEN_ARGUMENT_SYMBOL = "T_OPEN_ARGUMENT_SYMBOL"; |
||
21 | const T_CLOSE_ARGUMENT_SYMBOL = "T_CLOSE_ARGUMENT_SYMBOL"; |
||
22 | const T_NAME = "T_NAME"; |
||
23 | const T_ABBREV = "T_ABBREV"; |
||
24 | const T_ABBREV_SEPARATOR = "T_ABBREV_SEPARATOR"; |
||
25 | const T_STRING_WITH_SPACES = "T_STRING_WITH_SPACES"; |
||
26 | const T_EQUAL_SIGN = "T_EQUAL_SIGN"; |
||
27 | const T_OPTIONAL_MARK = "T_OPTIONAL_MARK"; |
||
28 | const T_WHITESPACES = "T_WHITESPACES"; |
||
29 | |||
30 | private static $tokenToRegex = null; |
||
31 | |||
32 | private static function getTokenToRegex() |
||
52 | |||
53 | /** |
||
54 | * @var string |
||
55 | */ |
||
56 | private $string; |
||
57 | |||
58 | /** |
||
59 | * @var int |
||
60 | */ |
||
61 | private $strlen; |
||
62 | |||
63 | /** |
||
64 | * @var int |
||
65 | */ |
||
66 | private $offset = 0; |
||
67 | |||
68 | /** |
||
69 | * @var string |
||
70 | */ |
||
71 | private $lastOccurrence; |
||
72 | |||
73 | /** |
||
74 | * DefinitionLexer constructor. |
||
75 | * @param string $string |
||
76 | */ |
||
77 | public function __construct($string) |
||
82 | |||
83 | public function getNextToken() |
||
101 | |||
102 | public function getLastOccurrence() |
||
106 | } |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..