3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = new class() {}; class_alias($a::class, \array::class); function foo(\array $x) { print_r($x); } foo($a); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Wsb8F
function name:  (null)
number of ops:  13
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_ANON_CLASS                               <unknown> 
          1        NEW                                              $2      $1
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
    5     4        INIT_FCALL                                               'class_alias'
          5        FETCH_CLASS_NAME                                 ~5      !0
          6        SEND_VAL                                                 ~5
          7        SEND_VAL                                                 'array'
          8        DO_ICALL                                                 
   11     9        INIT_FCALL                                               'foo'
         10        SEND_VAR                                                 !0
         11        DO_FCALL                                      0          
   13    12      > RETURN                                                   1

Function foo:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Wsb8F
function name:  foo
number of ops:  5
compiled vars:  !0 = $x
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    8     1        INIT_FCALL                                               'print_r'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                                 
    9     4      > RETURN                                                   null

End of function foo

Class class@anonymous: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.68 ms | 1003 KiB | 16 Q