3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public static function is($val) { define(__CLASS__, $val); } } Foo::is('bar'); var_dump(Foo);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1Sabv
function name:  (null)
number of ops:  8
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   INIT_STATIC_METHOD_CALL                                  'Foo', 'is'
          1        SEND_VAL                                                 'bar'
          2        DO_FCALL                                      0          
    9     3        INIT_FCALL                                               'var_dump'
          4        FETCH_CONSTANT                                   ~1      'Foo'
          5        SEND_VAL                                                 ~1
          6        DO_ICALL                                                 
          7      > RETURN                                                   1

Class Foo:
Function is:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1Sabv
function name:  is
number of ops:  6
compiled vars:  !0 = $val
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        INIT_FCALL                                               'define'
          2        SEND_VAL                                                 'Foo'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                                 
    5     5      > RETURN                                                   null

End of function is

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
180.25 ms | 1394 KiB | 17 Q