3v4l.org

run code in 300+ PHP versions simultaneously
<?php $langs = array("en", "de", "pt"); foreach($langs as $val) { $array[$val] = array_filter($langs, function($c) use($val) {return $c != $val;}); } print_r($array);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 12
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 12
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 12
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 12
filename:       /in/kBFgQ
function name:  (null)
number of ops:  17
compiled vars:  !0 = $langs, !1 = $val, !2 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    4     1      > FE_RESET_R                                       $4      !0, ->12
          2    > > FE_FETCH_R                                               $4, !1, ->12
    5     3    >   INIT_FCALL                                               'array_filter'
          4        SEND_VAR                                                 !0
          5        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FkBFgQ%3A5%240'
          6        BIND_LEXICAL                                             ~6, !1
          7        SEND_VAL                                                 ~6
          8        DO_ICALL                                         $7      
          9        ASSIGN_DIM                                               !2, !1
         10        OP_DATA                                                  $7
    4    11      > JMP                                                      ->2
         12    >   FE_FREE                                                  $4
    8    13        INIT_FCALL                                               'print_r'
         14        SEND_VAR                                                 !2
         15        DO_ICALL                                                 
         16      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FkBFgQ%3A5%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kBFgQ
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $c, !1 = $val
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
          1        BIND_STATIC                                              !1
          2        IS_NOT_EQUAL                                     ~2      !0, !1
          3      > RETURN                                                   ~2
          4*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FkBFgQ%3A5%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.28 ms | 1400 KiB | 17 Q