3v4l.org

run code in 300+ PHP versions simultaneously
<?php $ar = [ [ 'a' => 'blah', 'b' => 'bleh', ], [ 'a' => 'blah', 'b' => 'bleh', ], [ 'a' => 'blah', 'b' => 'bleh', ], ]; //lets change all the 'bleh' values to the matrix version. foreach($ar as &$record){ foreach($record as $key => $val){ if($val === 'bleh'){ $record[$key] = 'THERE IS NO SPOON'; } } } var_dump($ar);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 125) Position 1 = 2, Position 2 = 13
Branch analysis from position: 2
2 jumps found. (Code = 126) Position 1 = 3, Position 2 = 13
Branch analysis from position: 3
2 jumps found. (Code = 77) Position 1 = 4, Position 2 = 11
Branch analysis from position: 4
2 jumps found. (Code = 78) Position 1 = 5, Position 2 = 11
Branch analysis from position: 5
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 10
Branch analysis from position: 8
1 jumps found. (Code = 42) Position 1 = 4
Branch analysis from position: 4
Branch analysis from position: 10
Branch analysis from position: 11
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 11
Branch analysis from position: 13
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 13
filename:       /in/PfSMc
function name:  (null)
number of ops:  18
compiled vars:  !0 = $ar, !1 = $record, !2 = $val, !3 = $key
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
   18     1      > FE_RESET_RW                                      $5      !0, ->13
          2    > > FE_FETCH_RW                                              $5, !1, ->13
   19     3    > > FE_RESET_R                                       $6      !1, ->11
          4    > > FE_FETCH_R                                       ~7      $6, !2, ->11
          5    >   ASSIGN                                                   !3, ~7
   20     6        IS_IDENTICAL                                             !2, 'bleh'
          7      > JMPZ                                                     ~9, ->10
   21     8    >   ASSIGN_DIM                                               !1, !3
          9        OP_DATA                                                  'THERE+IS+NO+SPOON'
   19    10    > > JMP                                                      ->4
         11    >   FE_FREE                                                  $6
   18    12      > JMP                                                      ->2
         13    >   FE_FREE                                                  $5
   26    14        INIT_FCALL                                               'var_dump'
         15        SEND_VAR                                                 !0
         16        DO_ICALL                                                 
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.68 ms | 1400 KiB | 15 Q