3v4l.org

run code in 500+ PHP versions simultaneously
<?php $array = ['a', 'b', 'c']; var_dump(array_is_list($array)); $filter = array_filter($array, fn ($item) => $item != 'a'); var_dump(array_is_list($filter));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JZS9N
function name:  (null)
number of ops:  20
compiled vars:  !0 = $array, !1 = $filter
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
    5     1        INIT_FCALL                                                   'var_dump'
          2        INIT_FCALL                                                   'array_is_list'
          3        SEND_VAR                                                     !0
          4        DO_ICALL                                             $3      
          5        SEND_VAR                                                     $3
          6        DO_ICALL                                                     
    7     7        INIT_FCALL                                                   'array_filter'
          8        SEND_VAR                                                     !0
          9        DECLARE_LAMBDA_FUNCTION                              ~5      [0]
         10        SEND_VAL                                                     ~5
         11        DO_ICALL                                             $6      
         12        ASSIGN                                                       !1, $6
    9    13        INIT_FCALL                                                   'var_dump'
         14        INIT_FCALL                                                   'array_is_list'
         15        SEND_VAR                                                     !1
         16        DO_ICALL                                             $8      
         17        SEND_VAR                                                     $8
         18        DO_ICALL                                                     
         19      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/JZS9N
function name:  {closure:/in/JZS9N:7}
number of ops:  4
compiled vars:  !0 = $item
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    7     0  E >   RECV                                                 !0      
          1        IS_NOT_EQUAL                                         ~1      !0, 'a'
          2      > RETURN                                                       ~1
          3*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
166.71 ms | 1773 KiB | 16 Q