@@ -12,6 +12,9 @@ discard block |
||
12 | 12 | return ($tokens[0][0] == T_CONSTANT_ENCAPSED_STRING) && ($nextToken !== '.'); |
13 | 13 | } |
14 | 14 | |
15 | + /** |
|
16 | + * @param string $funcName |
|
17 | + */ |
|
15 | 18 | public static function isGlobalCall($funcName, &$tokens, $i) |
16 | 19 | { |
17 | 20 | $expectedTokens = [ |
@@ -46,6 +49,9 @@ discard block |
||
46 | 49 | return self::checkTokens($expectedTokens, $tokens, $i); |
47 | 50 | } |
48 | 51 | |
52 | + /** |
|
53 | + * @param string $methodName |
|
54 | + */ |
|
49 | 55 | public static function isMethodCallOnThis($methodName, &$tokens, $i) |
50 | 56 | { |
51 | 57 | $expectedTokens = [ |
@@ -45,6 +45,9 @@ |
||
45 | 45 | return [$token, $i]; |
46 | 46 | } |
47 | 47 | |
48 | + /** |
|
49 | + * @param string[] $tokenType |
|
50 | + */ |
|
48 | 51 | public static function forwardTo($tokens, $i, $tokenType) |
49 | 52 | { |
50 | 53 | $i++; |
@@ -3,7 +3,6 @@ |
||
3 | 3 | namespace Imanghafoori\LaravelMicroscope; |
4 | 4 | |
5 | 5 | use Illuminate\Support\Str; |
6 | -use Imanghafoori\LaravelMicroscope\Analyzers\FunctionCall; |
|
7 | 6 | use Imanghafoori\LaravelMicroscope\Analyzers\NamespaceCorrector; |
8 | 7 | use Imanghafoori\LaravelMicroscope\Analyzers\Refactor; |
9 | 8 | use Imanghafoori\LaravelMicroscope\LaravelPaths\FilePath; |
@@ -2,7 +2,6 @@ |
||
2 | 2 | |
3 | 3 | namespace Imanghafoori\LaravelMicroscope\Refactors; |
4 | 4 | |
5 | -use Imanghafoori\LaravelMicroscope\Analyzers\FunctionCall; |
|
6 | 5 | use Imanghafoori\LaravelMicroscope\Analyzers\Refactor; |
7 | 6 | use Imanghafoori\LaravelMicroscope\Analyzers\TokenManager; |
8 | 7 |
@@ -108,6 +108,9 @@ |
||
108 | 108 | return $refactoredTokens; |
109 | 109 | } |
110 | 110 | |
111 | + /** |
|
112 | + * @param integer $i |
|
113 | + */ |
|
111 | 114 | private static function removeSemi(&$tokens, $i) |
112 | 115 | { |
113 | 116 | [$next, $u] = TokenManager::getNextToken($tokens, $i); |