3v4l.org

run code in 300+ PHP versions simultaneously
<?php $file = new \SplTempFileObject(); for ($i = 0; $i < 100; $i++) { $file->fwrite("Foo\n"); } $file->seek(50); var_dump($file->fgets()); var_dump($file->key());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 5
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 5
2 jumps found. (Code = 44) Position 1 = 11, Position 2 = 5
Branch analysis from position: 11
Branch analysis from position: 5
filename:       /in/ECmpL
function name:  (null)
number of ops:  25
compiled vars:  !0 = $file, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $2      'SplTempFileObject'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
    5     3        ASSIGN                                                   !1, 0
          4      > JMP                                                      ->9
    6     5    >   INIT_METHOD_CALL                                         !0, 'fwrite'
          6        SEND_VAL_EX                                              'Foo%0A'
          7        DO_FCALL                                      0          
    5     8        PRE_INC                                                  !1
          9    >   IS_SMALLER                                               !1, 100
         10      > JMPNZ                                                    ~8, ->5
    9    11    >   INIT_METHOD_CALL                                         !0, 'seek'
         12        SEND_VAL_EX                                              50
         13        DO_FCALL                                      0          
   11    14        INIT_FCALL                                               'var_dump'
         15        INIT_METHOD_CALL                                         !0, 'fgets'
         16        DO_FCALL                                      0  $10     
         17        SEND_VAR                                                 $10
         18        DO_ICALL                                                 
   12    19        INIT_FCALL                                               'var_dump'
         20        INIT_METHOD_CALL                                         !0, 'key'
         21        DO_FCALL                                      0  $12     
         22        SEND_VAR                                                 $12
         23        DO_ICALL                                                 
         24      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
184.4 ms | 1395 KiB | 15 Q