3v4l.org

run code in 300+ PHP versions simultaneously
<?php const general = 1; const verified = 2; const premier = 4; const boost = 8; $status = 10; function isEnrolled() { return ($status & boost) == boost; } print_r(isEnrolled());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LDReE
function name:  (null)
number of ops:  11
compiled vars:  !0 = $status
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_CONST                                            'general', 1
    4     1        DECLARE_CONST                                            'verified', 2
    5     2        DECLARE_CONST                                            'premier', 4
    6     3        DECLARE_CONST                                            'boost', 8
    8     4        ASSIGN                                                   !0, 10
   15     5        INIT_FCALL                                               'print_r'
          6        INIT_FCALL                                               'isenrolled'
          7        DO_FCALL                                      0  $2      
          8        SEND_VAR                                                 $2
          9        DO_ICALL                                                 
         10      > RETURN                                                   1

Function isenrolled:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/LDReE
function name:  isEnrolled
number of ops:  6
compiled vars:  !0 = $status
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   FETCH_CONSTANT                                   ~1      'boost'
          1        BW_AND                                           ~2      !0, ~1
          2        FETCH_CONSTANT                                   ~3      'boost'
          3        IS_EQUAL                                         ~4      ~2, ~3
          4      > RETURN                                                   ~4
   13     5*     > RETURN                                                   null

End of function isenrolled

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
173.93 ms | 942 KiB | 17 Q