3v4l.org

run code in 500+ PHP versions simultaneously
<?php class One {} class Two {} class Three {} function check(One|Two|Three ...$numbers): void { var_dump($numbers); } check(...[new One, new Two]); check(...[new One, new StdClass]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/aIYLn
function name:  (null)
number of ops:  21
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    8     0  E >   INIT_FCALL                                                   'check'
          1        NEW                                                  $0      'One'
          2        DO_FCALL                                          0          
          3        INIT_ARRAY                                           ~2      $0
          4        NEW                                                  $3      'Two'
          5        DO_FCALL                                          0          
          6        ADD_ARRAY_ELEMENT                                    ~2      $3
          7        SEND_UNPACK                                                  ~2
          8        CHECK_UNDEF_ARGS                                             
          9        DO_FCALL                                          1          
    9    10        INIT_FCALL                                                   'check'
         11        NEW                                                  $6      'One'
         12        DO_FCALL                                          0          
         13        INIT_ARRAY                                           ~8      $6
         14        NEW                                                  $9      'StdClass'
         15        DO_FCALL                                          0          
         16        ADD_ARRAY_ELEMENT                                    ~8      $9
         17        SEND_UNPACK                                                  ~8
         18        CHECK_UNDEF_ARGS                                             
         19        DO_FCALL                                          1          
         20      > RETURN                                                       1

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

End of function check

Class One: [no user functions]
Class Two: [no user functions]
Class Three: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
166.79 ms | 1767 KiB | 16 Q