3v4l.org

run code in 300+ PHP versions simultaneously
<?php // This is actually working as expected // now see http://3v4l.org/mqAHJ namespace My\Psr0\SuperNameSpace; class Foo { public function bar() { return array_keys(array('a','b','c')); } } $foo = new Foo(); var_dump($foo->bar());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LtJ3p
function name:  (null)
number of ops:  9
compiled vars:  !0 = $foo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   NEW                                              $1      'My%5CPsr0%5CSuperNameSpace%5CFoo'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   16     3        INIT_NS_FCALL_BY_NAME                                    'My%5CPsr0%5CSuperNameSpace%5Cvar_dump'
          4        INIT_METHOD_CALL                                         !0, 'bar'
          5        DO_FCALL                                      0  $4      
          6        SEND_VAR_NO_REF_EX                                       $4
          7        DO_FCALL                                      0          
          8      > RETURN                                                   1

Class My\Psr0\SuperNameSpace\Foo:
Function bar:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LtJ3p
function name:  bar
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   INIT_NS_FCALL_BY_NAME                                    'My%5CPsr0%5CSuperNameSpace%5Carray_keys'
          1        SEND_VAL_EX                                              <array>
          2        DO_FCALL                                      0  $0      
          3      > RETURN                                                   $0
   12     4*     > RETURN                                                   null

End of function bar

End of class My\Psr0\SuperNameSpace\Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.11 ms | 1395 KiB | 17 Q