3v4l.org

run code in 500+ PHP versions simultaneously
<?php class Obj { } function callback($content) { return isset($GLOBALS['a']) ? $content : 'oops'; } ob_start('callback'); $a = new Obj(); //$b = $a; echo 'okay'; //ob_end_flush(); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/H27Fh
function name:  (null)
number of ops:  8
compiled vars:  !0 = $a
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   11     0  E >   INIT_FCALL                                                   'ob_start'
          1        SEND_VAL                                                     'callback'
          2        DO_ICALL                                                     
   12     3        NEW                                                  $2      'Obj'
          4        DO_FCALL                                          0          
          5        ASSIGN                                                       !0, $2
   14     6        ECHO                                                         'okay'
   17     7      > RETURN                                                       1

Function callback:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 5
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 6
Branch analysis from position: 6
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/H27Fh
function name:  callback
number of ops:  8
compiled vars:  !0 = $content
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    6     0  E >   RECV                                                 !0      
    8     1        ISSET_ISEMPTY_VAR                                 2          'a'
          2      > JMPZ                                                         ~1, ->5
          3    >   QM_ASSIGN                                            ~2      !0
          4      > JMP                                                          ->6
          5    >   QM_ASSIGN                                            ~2      'oops'
          6    > > RETURN                                                       ~2
    9     7*     > RETURN                                                       null

End of function callback

Class Obj: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
163.47 ms | 3259 KiB | 14 Q