3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Example { public $a = 1; public function foo() { var_dump($this->a); } public function bar() { self::foo(); } } $ex = new Example; $ex::bar();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m0EqV
function name:  (null)
number of ops:  7
compiled vars:  !0 = $ex
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   16     0  E >   NEW                                              $1      'Example'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   17     3        FETCH_CLASS                                   0  $4      !0
          4        INIT_STATIC_METHOD_CALL                                  $4, 'bar'
          5        DO_FCALL                                      0          
          6      > RETURN                                                   1

Class Example:
Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m0EqV
function name:  foo
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   INIT_FCALL                                               'var_dump'
          1        FETCH_OBJ_R                                      ~0      'a'
          2        SEND_VAL                                                 ~0
          3        DO_ICALL                                                 
    9     4      > RETURN                                                   null

End of function foo

Function bar:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/m0EqV
function name:  bar
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   INIT_STATIC_METHOD_CALL                                  'foo'
          1        DO_FCALL                                      0          
   13     2      > RETURN                                                   null

End of function bar

End of class Example.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.59 ms | 1395 KiB | 15 Q