3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array(); $arr["a"] = "A"; $arr["b"] = "B"; $str = array_filter($arr, function($e1){ echo $e1; return $e1; }); var_dump($str);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7Ri7b
function name:  (null)
number of ops:  15
compiled vars:  !0 = $arr, !1 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    3     1        ASSIGN_DIM                                               !0, 'a'
          2        OP_DATA                                                  'A'
    4     3        ASSIGN_DIM                                               !0, 'b'
          4        OP_DATA                                                  'B'
    6     5        INIT_FCALL                                               'array_filter'
          6        SEND_VAR                                                 !0
          7        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F7Ri7b%3A6%240'
    9     8        SEND_VAL                                                 ~5
          9        DO_ICALL                                         $6      
    6    10        ASSIGN                                                   !1, $6
   10    11        INIT_FCALL                                               'var_dump'
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2F7Ri7b%3A6%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/7Ri7b
function name:  {closure}
number of ops:  4
compiled vars:  !0 = $e1
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV                                             !0      
    7     1        ECHO                                                     !0
    8     2      > RETURN                                                   !0
    9     3*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F7Ri7b%3A6%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
212.4 ms | 1399 KiB | 17 Q