3v4l.org

run code in 300+ PHP versions simultaneously
<?php $f = new SplFileObject('php://memory', 'rw'); $f->fwrite("A\nB"); var_dump($f->current(), (string) $f);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/30v8r
function name:  (null)
number of ops:  16
compiled vars:  !0 = $f
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   NEW                                              $1      'SplFileObject'
          1        SEND_VAL_EX                                              'php%3A%2F%2Fmemory'
          2        SEND_VAL_EX                                              'rw'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !0, $1
    4     5        INIT_METHOD_CALL                                         !0, 'fwrite'
          6        SEND_VAL_EX                                              'A%0AB'
          7        DO_FCALL                                      0          
    5     8        INIT_FCALL                                               'var_dump'
          9        INIT_METHOD_CALL                                         !0, 'current'
         10        DO_FCALL                                      0  $5      
         11        SEND_VAR                                                 $5
         12        CAST                                          6  ~6      !0
         13        SEND_VAL                                                 ~6
         14        DO_ICALL                                                 
         15      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.78 ms | 1398 KiB | 15 Q