3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Tools { public static $notify; public function test() { var_dump(self::$notify, (boolean)self::$notify, !self::$notify); } } $debug = true; if ($debug) { Tools::$notify = false; } $tools = new Tools; $tools->test();
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 2, Position 2 = 4
Branch analysis from position: 2
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
filename:       /in/K5ooD
function name:  (null)
number of ops:  10
compiled vars:  !0 = $debug, !1 = $tools
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   14     0  E >   ASSIGN                                                   !0, <true>
   15     1      > JMPZ                                                     !0, ->4
   16     2    >   ASSIGN_STATIC_PROP                                       'notify', 'Tools'
          3        OP_DATA                                                  <false>
   19     4    >   NEW                                              $4      'Tools'
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !1, $4
   21     7        INIT_METHOD_CALL                                         !1, 'test'
          8        DO_FCALL                                      0          
          9      > RETURN                                                   1

Class Tools:
Function test:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/K5ooD
function name:  test
number of ops:  11
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'var_dump'
          1        FETCH_STATIC_PROP_R          global lock         ~0      'notify'
          2        SEND_VAL                                                 ~0
          3        FETCH_STATIC_PROP_R          unknown             ~1      'notify'
          4        BOOL                                             ~2      ~1
          5        SEND_VAL                                                 ~2
          6        FETCH_STATIC_PROP_R          unknown             ~3      'notify'
          7        BOOL_NOT                                         ~4      ~3
          8        SEND_VAL                                                 ~4
          9        DO_ICALL                                                 
   10    10      > RETURN                                                   null

End of function test

End of class Tools.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.49 ms | 1395 KiB | 15 Q