3v4l.org

run code in 300+ PHP versions simultaneously
<?php $test = array("", null, 1, "1", array(), StdClass(), 0, "0"); foreach ($test as $item){ var_dump(intval($test)); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 12, Position 2 = 18
Branch analysis from position: 12
2 jumps found. (Code = 78) Position 1 = 13, Position 2 = 18
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 12
Branch analysis from position: 12
Branch analysis from position: 18
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 18
filename:       /in/lnfYs
function name:  (null)
number of ops:  20
compiled vars:  !0 = $test, !1 = $item
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_ARRAY                                       ~2      ''
          1        ADD_ARRAY_ELEMENT                                ~2      null
          2        ADD_ARRAY_ELEMENT                                ~2      1
          3        ADD_ARRAY_ELEMENT                                ~2      '1'
          4        ADD_ARRAY_ELEMENT                                ~2      <array>
          5        INIT_FCALL_BY_NAME                                       'StdClass'
          6        DO_FCALL                                      0  $3      
          7        ADD_ARRAY_ELEMENT                                ~2      $3
          8        ADD_ARRAY_ELEMENT                                ~2      0
          9        ADD_ARRAY_ELEMENT                                ~2      '0'
         10        ASSIGN                                                   !0, ~2
    5    11      > FE_RESET_R                                       $5      !0, ->18
         12    > > FE_FETCH_R                                               $5, !1, ->18
    6    13    >   INIT_FCALL                                               'var_dump'
         14        CAST                                          4  ~6      !0
         15        SEND_VAL                                                 ~6
         16        DO_ICALL                                                 
    5    17      > JMP                                                      ->12
         18    >   FE_FREE                                                  $5
    7    19      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.18 ms | 1395 KiB | 15 Q