3v4l.org

run code in 300+ PHP versions simultaneously
<?php error_reporting(0); $File = new SplFileObject(__FILE__); echo 'SplFileObject::__toString(): ', (string) htmlspecialchars($File), PHP_EOL; echo 'SplFileInfo::__toString(): ', (string) htmlspecialchars($File->getFileInfo()), PHP_EOL; echo PHP_EOL; echo "Now let's loop through the file:", PHP_EOL, PHP_EOL; foreach ($File as $line) { echo htmlspecialchars($line), PHP_EOL; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 28, Position 2 = 35
Branch analysis from position: 28
2 jumps found. (Code = 78) Position 1 = 29, Position 2 = 35
Branch analysis from position: 29
1 jumps found. (Code = 42) Position 1 = 28
Branch analysis from position: 28
Branch analysis from position: 35
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 35
filename:       /in/akKiF
function name:  (null)
number of ops:  37
compiled vars:  !0 = $File, !1 = $line
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   INIT_FCALL                                               'error_reporting'
          1        SEND_VAL                                                 0
          2        DO_ICALL                                                 
    5     3        NEW                                              $3      'SplFileObject'
          4        SEND_VAL_EX                                              '%2Fin%2FakKiF'
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !0, $3
    7     7        ECHO                                                     'SplFileObject%3A%3A__toString%28%29%3A+'
          8        INIT_FCALL                                               'htmlspecialchars'
          9        SEND_VAR                                                 !0
         10        DO_ICALL                                         $6      
         11        CAST                                          6  ~7      $6
         12        ECHO                                                     ~7
         13        ECHO                                                     '%0A'
    8    14        ECHO                                                     'SplFileInfo%3A%3A__toString%28%29%3A+'
         15        INIT_FCALL                                               'htmlspecialchars'
         16        INIT_METHOD_CALL                                         !0, 'getFileInfo'
         17        DO_FCALL                                      0  $8      
         18        SEND_VAR                                                 $8
         19        DO_ICALL                                         $9      
         20        CAST                                          6  ~10     $9
         21        ECHO                                                     ~10
         22        ECHO                                                     '%0A'
    9    23        ECHO                                                     '%0A'
   10    24        ECHO                                                     'Now+let%27s+loop+through+the+file%3A'
         25        ECHO                                                     '%0A'
         26        ECHO                                                     '%0A'
   11    27      > FE_RESET_R                                       $11     !0, ->35
         28    > > FE_FETCH_R                                               $11, !1, ->35
   13    29    >   INIT_FCALL                                               'htmlspecialchars'
         30        SEND_VAR                                                 !1
         31        DO_ICALL                                         $12     
         32        ECHO                                                     $12
         33        ECHO                                                     '%0A'
   11    34      > JMP                                                      ->28
         35    >   FE_FREE                                                  $11
   14    36      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.69 ms | 1396 KiB | 17 Q