3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = ['' => 1]; var_dump($a[''] ?? 3); var_dump($a[''] ?: 2);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/pdmog
function name:  (null)
number of ops:  14
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1        INIT_FCALL                                               'var_dump'
          2        FETCH_DIM_IS                                     ~2      !0, ''
          3        COALESCE                                         ~3      ~2
          4        QM_ASSIGN                                        ~3      3
          5        SEND_VAL                                                 ~3
          6        DO_ICALL                                                 
    6     7        INIT_FCALL                                               'var_dump'
          8        FETCH_DIM_R                                      ~5      !0, ''
          9        JMP_SET                                          ~6      ~5, ->11
         10        QM_ASSIGN                                        ~6      2
         11        SEND_VAL                                                 ~6
         12        DO_ICALL                                                 
         13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.11 ms | 1394 KiB | 15 Q