3v4l.org

run code in 300+ PHP versions simultaneously
<?php $mystring = null; if (empty($mystring)) { echo 'empty'; } if ($mystring == null) { echo 'null'; // and warning } if (!isset($mystring)) { echo 'not set'; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 4
Branch analysis from position: 3
2 jumps found. (Code = 43) Position 1 = 6, Position 2 = 7
Branch analysis from position: 6
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 11
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
Branch analysis from position: 7
Branch analysis from position: 4
filename:       /in/pn4IJ
function name:  (null)
number of ops:  12
compiled vars:  !0 = $mystring
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, null
    3     1        ISSET_ISEMPTY_CV                                         !0
          2      > JMPZ                                                     ~2, ->4
    4     3    >   ECHO                                                     'empty'
    6     4    >   IS_EQUAL                                                 !0, null
          5      > JMPZ                                                     ~3, ->7
    7     6    >   ECHO                                                     'null'
    9     7    >   ISSET_ISEMPTY_CV                                 ~4      !0
          8        BOOL_NOT                                         ~5      ~4
          9      > JMPZ                                                     ~5, ->11
   10    10    >   ECHO                                                     'not+set'
   11    11    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.72 ms | 1397 KiB | 13 Q