3v4l.org

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

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

End of function %00%7Bclosure%7D%2Fin%2FX0mOc%3A9%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
161.28 ms | 1395 KiB | 17 Q