3v4l.org

run code in 500+ PHP versions simultaneously
<?php declare(strict_types=1); /** * @param array<string,mixed> $a */ function f(array $headers): void { foreach ($headers as $name => $value) { if (str_starts_with($name, 'x-')) { // ... } } } f(['0' => 'hello php']);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/uM3UM
function name:  (null)
number of ops:  4
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_FCALL                                                   'f'
          1        SEND_VAL                                                     <array>
          2        DO_FCALL                                          0          
          3      > RETURN                                                       1

Function f:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 7
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 7
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 6
Branch analysis from position: 6
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 6
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/uM3UM
function name:  f
number of ops:  9
compiled vars:  !0 = $headers, !1 = $value, !2 = $name
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    8     0  E >   RECV                                                 !0      
    9     1      > FE_RESET_R                                           $3      !0, ->7
          2    > > FE_FETCH_R                                           ~4      $3, !1, ->7
          3    >   ASSIGN                                                       !2, ~4
   10     4        FRAMELESS_ICALL_2                str_starts_with      ~6      !2, 'x-'
          5      > JMPZ                                                         ~6, ->6
    9     6    > > JMP                                                          ->2
          7    >   FE_FREE                                                      $3
   14     8      > RETURN                                                       null

End of function f

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
168.03 ms | 3410 KiB | 14 Q