| @@ 2108-2117 (lines=10) @@ | ||
| 2105 | echo "=> Found function before scope opener for $stackPtr:$type, processing manually".PHP_EOL; |
|
| 2106 | } |
|
| 2107 | ||
| 2108 | if (isset($tokens[$i]['scope_closer']) === true) { |
|
| 2109 | // We've already processed this closure. |
|
| 2110 | if (PHP_CODESNIFFER_VERBOSITY > 1) { |
|
| 2111 | echo str_repeat("\t", $depth); |
|
| 2112 | echo '* already processed, skipping *'.PHP_EOL; |
|
| 2113 | } |
|
| 2114 | ||
| 2115 | $i = $tokens[$i]['scope_closer']; |
|
| 2116 | continue; |
|
| 2117 | } |
|
| 2118 | ||
| 2119 | $i = self::_recurseScopeMap( |
|
| 2120 | $tokens, |
|
| @@ 2270-2279 (lines=10) @@ | ||
| 2267 | // If the first non-whitespace/comment token is a |
|
| 2268 | // variable or object operator then this is an opener |
|
| 2269 | // for a string offset and not a scope. |
|
| 2270 | if ($tokens[$x]['code'] === T_VARIABLE |
|
| 2271 | || $tokens[$x]['code'] === T_OBJECT_OPERATOR |
|
| 2272 | ) { |
|
| 2273 | if (PHP_CODESNIFFER_VERBOSITY > 1) { |
|
| 2274 | echo str_repeat("\t", $depth); |
|
| 2275 | echo '* ignoring curly brace *'.PHP_EOL; |
|
| 2276 | } |
|
| 2277 | ||
| 2278 | $ignore++; |
|
| 2279 | }//end if |
|
| 2280 | ||
| 2281 | break; |
|
| 2282 | }//end if |
|
| @@ 1147-1155 (lines=9) @@ | ||
| 1144 | echo str_repeat("\t", count($classStack)); |
|
| 1145 | echo "\t* token $label converted from T_STRING to T_PROPERTY *".PHP_EOL; |
|
| 1146 | } |
|
| 1147 | } else { |
|
| 1148 | $tokens[$label]['code'] = T_LABEL; |
|
| 1149 | $tokens[$label]['type'] = 'T_LABEL'; |
|
| 1150 | ||
| 1151 | if (PHP_CODESNIFFER_VERBOSITY > 1) { |
|
| 1152 | echo str_repeat("\t", count($classStack)); |
|
| 1153 | echo "\t* token $label converted from T_STRING to T_LABEL *".PHP_EOL; |
|
| 1154 | } |
|
| 1155 | }//end if |
|
| 1156 | }//end if |
|
| 1157 | }//end for |
|
| 1158 | ||