3v4l.org

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

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
165.05 ms | 1393 KiB | 13 Q