3v4l.org

run code in 300+ PHP versions simultaneously
<?php function array_key_isset($k, $a, $n=false){ return isset($a[$k]) || ($n && array_key_exists($k, $a)); } $a = [null, true]; var_demp([ array_key_isset($k, $a), array_key_isset($k, $a, true) ]);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/NofCm
function name:  (null)
number of ops:  16
compiled vars:  !0 = $a, !1 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   ASSIGN                                                   !0, <array>
    9     1        INIT_FCALL_BY_NAME                                       'var_demp'
   10     2        INIT_FCALL                                               'array_key_isset'
          3        SEND_VAR                                                 !1
          4        SEND_VAR                                                 !0
          5        DO_FCALL                                      0  $3      
          6        INIT_ARRAY                                       ~4      $3
   11     7        INIT_FCALL                                               'array_key_isset'
          8        SEND_VAR                                                 !1
          9        SEND_VAR                                                 !0
         10        SEND_VAL                                                 <true>
         11        DO_FCALL                                      0  $5      
         12        ADD_ARRAY_ELEMENT                                ~4      $5
         13        SEND_VAL_EX                                              ~4
         14        DO_FCALL                                      0          
   12    15      > RETURN                                                   1

Function array_key_isset:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 47) Position 1 = 5, Position 2 = 9
Branch analysis from position: 5
2 jumps found. (Code = 46) Position 1 = 6, Position 2 = 8
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
Branch analysis from position: 9
filename:       /in/NofCm
function name:  array_key_isset
number of ops:  11
compiled vars:  !0 = $k, !1 = $a, !2 = $n
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
          1        RECV                                             !1      
          2        RECV_INIT                                        !2      <false>
    4     3        ISSET_ISEMPTY_DIM_OBJ                         0  ~3      !1, !0
          4      > JMPNZ_EX                                         ~3      ~3, ->9
          5    > > JMPZ_EX                                          ~4      !2, ->8
          6    >   ARRAY_KEY_EXISTS                                 ~5      !0, !1
          7        BOOL                                             ~4      ~5
          8    >   BOOL                                             ~3      ~4
          9    > > RETURN                                                   ~3
    5    10*     > RETURN                                                   null

End of function array_key_isset

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
175.41 ms | 1399 KiB | 15 Q