3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { function __destruct() { echo "beep\n"; } } function alpha($foo) { echo "before\n"; $foo = "eat shit\n"; echo "after\n"; var_dump($foo); var_dump(func_get_args()); } alpha(new Foo);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kUXAe
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   18     0  E >   INIT_FCALL                                               'alpha'
          1        NEW                                              $0      'Foo'
          2        DO_FCALL                                      0          
          3        SEND_VAR                                                 $0
          4        DO_FCALL                                      0          
          5      > RETURN                                                   1

Function alpha:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kUXAe
function name:  alpha
number of ops:  12
compiled vars:  !0 = $foo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
   11     1        ECHO                                                     'before%0A'
   12     2        ASSIGN                                                   !0, 'eat+shit%0A'
   13     3        ECHO                                                     'after%0A'
   14     4        INIT_FCALL                                               'var_dump'
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                                 
   15     7        INIT_FCALL                                               'var_dump'
          8        FUNC_GET_ARGS                                    ~3      
          9        SEND_VAL                                                 ~3
         10        DO_ICALL                                                 
   16    11      > RETURN                                                   null

End of function alpha

Class Foo:
Function __destruct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kUXAe
function name:  __destruct
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   ECHO                                                     'beep%0A'
    6     1      > RETURN                                                   null

End of function __destruct

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.46 ms | 1397 KiB | 16 Q