3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { public function __construct(public array $foo = [1, 2, 3], public string $bar = 'baz') {} } var_dump(serialize(new Foo()));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4p6ve
function name:  (null)
number of ops:  9
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   INIT_FCALL                                               'var_dump'
          1        INIT_FCALL                                               'serialize'
          2        NEW                                              $0      'Foo'
          3        DO_FCALL                                      0          
          4        SEND_VAR                                                 $0
          5        DO_ICALL                                         $2      
          6        SEND_VAR                                                 $2
          7        DO_ICALL                                                 
          8      > RETURN                                                   1

Class Foo:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/4p6ve
function name:  __construct
number of ops:  7
compiled vars:  !0 = $foo, !1 = $bar
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV_INIT                                        !0      <array>
          1        RECV_INIT                                        !1      'baz'
          2        ASSIGN_OBJ                                               'foo'
          3        OP_DATA                                                  !0
          4        ASSIGN_OBJ                                               'bar'
          5        OP_DATA                                                  !1
          6      > RETURN                                                   null

End of function __construct

End of class Foo.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
137.17 ms | 998 KiB | 15 Q