3v4l.org

run code in 300+ PHP versions simultaneously
<?php $fruits = array("d" => "lemon", "a" => "orange", "b" => "banana", "c" => "apple"); function test_print($item, $key) { if ($item != "orange") echo "$item \n"; } array_walk($fruits, 'test_print'); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/EQQYk
function name:  (null)
number of ops:  6
compiled vars:  !0 = $fruits
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, <array>
    9     1        INIT_FCALL                                               'array_walk'
          2        SEND_REF                                                 !0
          3        SEND_VAL                                                 'test_print'
          4        DO_ICALL                                                 
   10     5      > RETURN                                                   1

Function test_print:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 7
Branch analysis from position: 4
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
filename:       /in/EQQYk
function name:  test_print
number of ops:  8
compiled vars:  !0 = $item, !1 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    6     2        IS_NOT_EQUAL                                             !0, 'orange'
          3      > JMPZ                                                     ~2, ->7
          4    >   NOP                                                      
          5        FAST_CONCAT                                      ~3      !0, '+%0A'
          6        ECHO                                                     ~3
    7     7    > > RETURN                                                   null

End of function test_print

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
159.23 ms | 1395 KiB | 15 Q