3v4l.org

run code in 300+ PHP versions simultaneously
<?php $class = new stdClass; echo (empty($class) ? 'empty' : 'not empty'); echo PHP_EOL; $array = []; echo (empty($array) ? 'empty' : 'not empty');
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 5, Position 2 = 7
Branch analysis from position: 5
1 jumps found. (Code = 42) Position 1 = 8
Branch analysis from position: 8
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 15
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 15
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 15
Branch analysis from position: 13
Branch analysis from position: 15
filename:       /in/ju0dg
function name:  (null)
number of ops:  18
compiled vars:  !0 = $class, !1 = $array
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $2      'stdClass'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
    4     3        ISSET_ISEMPTY_CV                                         !0
          4      > JMPZ                                                     ~5, ->7
          5    >   QM_ASSIGN                                        ~6      'empty'
          6      > JMP                                                      ->8
          7    >   QM_ASSIGN                                        ~6      'not+empty'
          8    >   ECHO                                                     ~6
    6     9        ECHO                                                     '%0A'
    7    10        ASSIGN                                                   !1, <array>
    8    11        ISSET_ISEMPTY_CV                                         !1
         12      > JMPZ                                                     ~8, ->15
         13    >   QM_ASSIGN                                        ~9      'empty'
         14      > JMP                                                      ->16
         15    >   QM_ASSIGN                                        ~9      'not+empty'
         16    >   ECHO                                                     ~9
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
124.67 ms | 1398 KiB | 13 Q