3v4l.org

run code in 500+ PHP versions simultaneously
<?php $arr = [ 'ticket_number' => 'sdfsdfsdf 2', 'strategy_id' => '5', 'journal_entries_strategy_conditions' => [ 0 => [ 'strategies_condition_id' => '' ], 1 => [ 'strategies_condition_id' => '1' ] ], 'timeframe' => '', ]; $filtered = array_filter(array_column($arr['journal_entries_strategy_conditions'], 'strategies_condition_id')); $arr['journal_entries_strategy_conditions'] = array_intersect_key($arr['journal_entries_strategy_conditions'], $filtered); var_dump($arr);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/iC66a
function name:  (null)
number of ops:  21
compiled vars:  !0 = $arr, !1 = $filtered
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, <array>
   17     1        INIT_FCALL                                                   'array_filter'
          2        INIT_FCALL                                                   'array_column'
          3        FETCH_DIM_R                                          ~3      !0, 'journal_entries_strategy_conditions'
          4        SEND_VAL                                                     ~3
          5        SEND_VAL                                                     'strategies_condition_id'
          6        DO_ICALL                                             $4      
          7        SEND_VAR                                                     $4
          8        DO_ICALL                                             $5      
          9        ASSIGN                                                       !1, $5
   19    10        INIT_FCALL                                                   'array_intersect_key'
         11        FETCH_DIM_R                                          ~8      !0, 'journal_entries_strategy_conditions'
         12        SEND_VAL                                                     ~8
         13        SEND_VAR                                                     !1
         14        DO_ICALL                                             $9      
         15        ASSIGN_DIM                                                   !0, 'journal_entries_strategy_conditions'
         16        OP_DATA                                                      $9
   21    17        INIT_FCALL                                                   'var_dump'
         18        SEND_VAR                                                     !0
         19        DO_ICALL                                                     
         20      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
159.33 ms | 2161 KiB | 17 Q