3v4l.org

run code in 300+ PHP versions simultaneously
<?php $t = []; (true) ? $t['test'] = 1 : null; (false) ?: $t['aaaa'] = 1; ! true ?: $t['bbbb'] = 1; var_dump($t);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 2, Position 2 = 6
Branch analysis from position: 2
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1dliu
function name:  (null)
number of ops:  22
compiled vars:  !0 = $t
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, <array>
    5     1      > JMPZ                                                     <true>, ->6
          2    >   ASSIGN_DIM                                       ~2      !0, 'test'
          3        OP_DATA                                                  1
          4        QM_ASSIGN                                        ~3      ~2
          5      > JMP                                                      ->7
          6    >   QM_ASSIGN                                        ~3      null
          7    >   FREE                                                     ~3
    6     8        JMP_SET                                          ~4      <false>, ->12
          9        ASSIGN_DIM                                       ~5      !0, 'aaaa'
         10        OP_DATA                                                  1
         11        QM_ASSIGN                                        ~4      ~5
         12        FREE                                                     ~4
    7    13        JMP_SET                                          ~6      <false>, ->17
         14        ASSIGN_DIM                                       ~7      !0, 'bbbb'
         15        OP_DATA                                                  1
         16        QM_ASSIGN                                        ~6      ~7
         17        FREE                                                     ~6
    9    18        INIT_FCALL                                               'var_dump'
         19        SEND_VAR                                                 !0
         20        DO_ICALL                                                 
         21      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.47 ms | 1395 KiB | 15 Q