3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a=bool(''); var_dump('' == $a and 'a' == $a and '' === (string)$a and 'a' === (string)$a);
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 46) Position 1 = 7, Position 2 = 9
Branch analysis from position: 7
2 jumps found. (Code = 46) Position 1 = 10, Position 2 = 13
Branch analysis from position: 10
2 jumps found. (Code = 46) Position 1 = 14, Position 2 = 17
Branch analysis from position: 14
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 17
Branch analysis from position: 13
Branch analysis from position: 9
filename:       /in/CBki5
function name:  (null)
number of ops:  20
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL_BY_NAME                                       'bool'
          1        SEND_VAL_EX                                              ''
          2        DO_FCALL                                      0  $1      
          3        ASSIGN                                                   !0, $1
    3     4        INIT_FCALL                                               'var_dump'
          5        IS_EQUAL                                         ~3      !0, ''
          6      > JMPZ_EX                                          ~3      ~3, ->9
          7    >   IS_EQUAL                                         ~4      !0, 'a'
          8        BOOL                                             ~3      ~4
          9    > > JMPZ_EX                                          ~3      ~3, ->13
         10    >   CAST                                          6  ~5      !0
         11        IS_IDENTICAL                                     ~6      ~5, ''
         12        BOOL                                             ~3      ~6
         13    > > JMPZ_EX                                          ~3      ~3, ->17
         14    >   CAST                                          6  ~7      !0
         15        IS_IDENTICAL                                     ~8      ~7, 'a'
         16        BOOL                                             ~3      ~8
         17    >   SEND_VAL                                                 ~3
         18        DO_ICALL                                                 
         19      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
144.97 ms | 1395 KiB | 15 Q