| @@ 63-82 (lines=20) @@ | ||
| 60 | } |
|
| 61 | } |
|
| 62 | ||
| 63 | public function enterFunctionCall(Insert $insert, Location $location, N\Expr\FuncCall $node) { |
|
| 64 | // Omit calls to closures, we would not be able to |
|
| 65 | // analyze them anyway atm. |
|
| 66 | // Omit functions in arrays, we would not be able to |
|
| 67 | // analyze them anyway atm. |
|
| 68 | if (!($node->name instanceof N\Expr\Variable || |
|
| 69 | $node->name instanceof N\Expr\ArrayDimFetch)) { |
|
| 70 | $function_reference = $insert->_function_reference |
|
| 71 | ( $node->name->parts[0] |
|
| 72 | , $location->_file() |
|
| 73 | , $location->_line() |
|
| 74 | , $location->_column() |
|
| 75 | ); |
|
| 76 | $this->insert_relation_into |
|
| 77 | ( $insert |
|
| 78 | , $location |
|
| 79 | , $function_reference |
|
| 80 | ); |
|
| 81 | } |
|
| 82 | } |
|
| 83 | ||
| 84 | public function enterGlobal(Insert $insert, Location $location, N\Stmt\Global_ $node) { |
|
| 85 | foreach ($node->vars as $var) { |
|
| @@ 60-79 (lines=20) @@ | ||
| 57 | } |
|
| 58 | } |
|
| 59 | ||
| 60 | public function enterFunctionCall(Insert $insert, Location $location, N\Expr\FuncCall $node) { |
|
| 61 | // Omit calls to closures, we would not be able to |
|
| 62 | // analyze them anyway atm. |
|
| 63 | // Omit functions in arrays, we would not be able to |
|
| 64 | // analyze them anyway atm. |
|
| 65 | if (!($node->name instanceof N\Expr\Variable || |
|
| 66 | $node->name instanceof N\Expr\ArrayDimFetch)) { |
|
| 67 | $function_reference = $insert->_function_reference |
|
| 68 | ( $node->name->parts[0] |
|
| 69 | , $location->_file() |
|
| 70 | , $location->_line() |
|
| 71 | , $location->_column() |
|
| 72 | ); |
|
| 73 | $this->insert_relation_into |
|
| 74 | ( $insert |
|
| 75 | , $location |
|
| 76 | , $function_reference |
|
| 77 | ); |
|
| 78 | } |
|
| 79 | } |
|
| 80 | ||
| 81 | public function enterExit(Insert $insert, Location $location, N\Expr\Exit_ $node) { |
|
| 82 | if ($node->getAttribute("kind") == N\Expr\Exit_::KIND_EXIT) { |
|