3v4l.org

run code in 500+ PHP versions simultaneously
<?php error_reporting(-1); phpversion() >= "5.6.0" or die(); $a = 1; unset($a); $g = array_filter($GLOBALS, function($k) { return !in_array($k, ["g", "HTTP_RAW_POST_DATA", "GLOBALS", "_FILES", "_REQUEST", "_SESSION", "_ENV", "_SERVER", "_GET", "_POST", "_COOKIE", "argv", "argc"]); }, ARRAY_FILTER_USE_KEY); var_dump(count($g)); var_dump($g); var_dump(array_keys($g)); var_dump($g['a']);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 7, Position 2 = 10
Branch analysis from position: 7
1 jumps found. (Code = 61) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hVcAB
function name:  (null)
number of ops:  38
compiled vars:  !0 = $a, !1 = $g
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                                   'error_reporting'
          1        SEND_VAL                                                     -1
          2        DO_ICALL                                                     
    3     3        INIT_FCALL                                                   'phpversion'
          4        DO_ICALL                                             $3      
          5        IS_SMALLER_OR_EQUAL                                  ~4      '5.6.0', $3
          6      > JMPNZ_EX                                             ~4      ~4, ->10
          7    > > INIT_FCALL                                                   'exit'
          8*       DO_ICALL                                             $5      
          9*       BOOL                                                 ~4      $5
    5    10    >   ASSIGN                                                       !0, 1
    6    11        UNSET_CV                                                     !0
    8    12        INIT_FCALL                                                   'array_filter'
         13        FETCH_GLOBALS                                        ~7      
         14        SEND_VAL                                                     ~7
         15        DECLARE_LAMBDA_FUNCTION                              ~8      [0]
   10    16        SEND_VAL                                                     ~8
         17        SEND_VAL                                                     2
    8    18        DO_ICALL                                             $9      
         19        ASSIGN                                                       !1, $9
   11    20        INIT_FCALL                                                   'var_dump'
         21        COUNT                                                ~11     !1
         22        SEND_VAL                                                     ~11
         23        DO_ICALL                                                     
   12    24        INIT_FCALL                                                   'var_dump'
         25        SEND_VAR                                                     !1
         26        DO_ICALL                                                     
   13    27        INIT_FCALL                                                   'var_dump'
         28        INIT_FCALL                                                   'array_keys'
         29        SEND_VAR                                                     !1
         30        DO_ICALL                                             $14     
         31        SEND_VAR                                                     $14
         32        DO_ICALL                                                     
   15    33        INIT_FCALL                                                   'var_dump'
         34        FETCH_DIM_R                                          ~16     !1, 'a'
         35        SEND_VAL                                                     ~16
         36        DO_ICALL                                                     
         37      > RETURN                                                       1


Dynamic Functions:
Dynamic Function 0
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hVcAB
function name:  {closure:/in/hVcAB:8}
number of ops:  5
compiled vars:  !0 = $k
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    8     0  E >   RECV                                                 !0      
    9     1        IN_ARRAY                                             ~1      !0, <array>
          2        BOOL_NOT                                             ~2      ~1
          3      > RETURN                                                       ~2
   10     4*     > RETURN                                                       null

End of Dynamic Function 0

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
172.56 ms | 2055 KiB | 20 Q