3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.33 ms | 1394 KiB | 15 Q