3v4l.org

run code in 300+ PHP versions simultaneously
<?php class foo { public static $var_1 = 'foo_var'; public static function printItem($string) { //echo 'Foo: ' . self::$var_1 . PHP_EOL; } public function printPHP() { echo 'PHP is great.' . PHP_EOL; } } class bar extends foo { public static $var_1 = 'bar_var'; public static function printItem($string) { echo 'Bar: ' . static::$var_1 . PHP_EOL; } } bar::printItem('baz');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eOvC4
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   27     0  E >   INIT_STATIC_METHOD_CALL                                  'bar', 'printItem'
          1        SEND_VAL                                                 'baz'
          2        DO_FCALL                                      0          
          3      > RETURN                                                   1

Class foo:
Function printitem:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eOvC4
function name:  printItem
number of ops:  2
compiled vars:  !0 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    9     1      > RETURN                                                   null

End of function printitem

Function printphp:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eOvC4
function name:  printPHP
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   ECHO                                                     'PHP+is+great.%0A'
   13     1      > RETURN                                                   null

End of function printphp

End of class foo.

Class bar:
Function printitem:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eOvC4
function name:  printItem
number of ops:  6
compiled vars:  !0 = $string
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   20     0  E >   RECV                                             !0      
   21     1        FETCH_STATIC_PROP_R          unknown             ~1      'var_1'
          2        CONCAT                                           ~2      'Bar%3A+', ~1
          3        CONCAT                                           ~3      ~2, '%0A'
          4        ECHO                                                     ~3
   22     5      > RETURN                                                   null

End of function printitem

Function printphp:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/eOvC4
function name:  printPHP
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   ECHO                                                     'PHP+is+great.%0A'
   13     1      > RETURN                                                   null

End of function printphp

End of class bar.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.04 ms | 1395 KiB | 13 Q