Skip to content

Commit a9622a5

Browse files
authored
Merge pull request #288 from remcotolsma/issue-284
Handle PHP 8 `T_NAME_FULLY_QUALIFIED` to fix issue #284
2 parents cbf1101 + 67a26c9 commit a9622a5

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/Utils/PhpFunctionsScanner.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,11 @@ public function getFunctions(array $constants = [])
9090
continue;
9191
}
9292

93+
if (defined('T_NAME_FULLY_QUALIFIED') && T_NAME_FULLY_QUALIFIED === $value[0]) {
94+
$value[0] = T_STRING;
95+
$value[1] = ltrim($value[1], '\\');
96+
}
97+
9398
switch ($value[0]) {
9499
case T_CONSTANT_ENCAPSED_STRING:
95100
//add an argument to the current function

0 commit comments

Comments
 (0)