3v4l.org

run code in 500+ PHP versions simultaneously
<?php #array to filter $data = ['foo' => 6]; #filter args $args = ['foo'=> ['filter' => FILTER_VALIDATE_INT,'flags' => FILTER_FORCE_ARRAY]]; $args['foo']['options']=[]; #create reference $options = &$args['foo']['options']; #set options $options['min_range']=1; $options['max_range']=5; #show the filter result print_r(filter_var_array($data,$args));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/83gXR
function name:  (null)
number of ops:  20
compiled vars:  !0 = $data, !1 = $args, !2 = $options
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                       !0, <array>
    6     1        ASSIGN                                                       !1, <array>
    7     2        FETCH_DIM_W                                          $5      !1, 'foo'
          3        ASSIGN_DIM                                                   $5, 'options'
          4        OP_DATA                                                      <array>
    9     5        FETCH_DIM_W                                          $7      !1, 'foo'
          6        FETCH_DIM_W                                          $8      $7, 'options'
          7        ASSIGN_REF                                                   !2, $8
   11     8        ASSIGN_DIM                                                   !2, 'min_range'
          9        OP_DATA                                                      1
   12    10        ASSIGN_DIM                                                   !2, 'max_range'
         11        OP_DATA                                                      5
   14    12        INIT_FCALL                                                   'print_r'
         13        INIT_FCALL                                                   'filter_var_array'
         14        SEND_VAR                                                     !0
         15        SEND_VAR                                                     !1
         16        DO_ICALL                                             $12     
         17        SEND_VAR                                                     $12
         18        DO_ICALL                                                     
         19      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
171.93 ms | 2988 KiB | 15 Q