3v4l.org

run code in 300+ PHP versions simultaneously
<?php $test = array_filter([ 'hello', 'good bye', 'something something', ], function($value) { return $value == 'something something'; }); var_dump(key($test));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/t81uA
function name:  (null)
number of ops:  13
compiled vars:  !0 = $test
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'array_filter'
    4     1        SEND_VAL                                                 <array>
    8     2        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2Ft81uA%3A8%240'
   10     3        SEND_VAL                                                 ~1
          4        DO_ICALL                                         $2      
    3     5        ASSIGN                                                   !0, $2
   11     6        INIT_FCALL                                               'var_dump'
          7        INIT_FCALL                                               'key'
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $4      
         10        SEND_VAR                                                 $4
         11        DO_ICALL                                                 
         12      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2Ft81uA%3A8%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/t81uA
function name:  {closure}
number of ops:  4
compiled vars:  !0 = $value
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   RECV                                             !0      
    9     1        IS_EQUAL                                         ~1      !0, 'something+something'
          2      > RETURN                                                   ~1
   10     3*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2Ft81uA%3A8%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
209.65 ms | 1395 KiB | 19 Q