3v4l.org

run code in 500+ PHP versions simultaneously
<?php $csv = <<<'CSV' first,line second,line third,line fourth,line fifth,line CSV; $file = new SplFileObject('php://memory', 'w+'); $file->fwrite($csv); $file->seek(1); print_r($file->fgetcsv());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/3Uh2L
function name:  (null)
number of ops:  18
compiled vars:  !0 = $csv, !1 = $file
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                       !0, 'first%2Cline%0Asecond%2Cline%0Athird%2Cline%0Afourth%2Cline%0Afifth%2Cline%0A'
   12     1        NEW                                                  $3      'SplFileObject'
          2        SEND_VAL_EX                                                  'php%3A%2F%2Fmemory'
          3        SEND_VAL_EX                                                  'w%2B'
          4        DO_FCALL                                          0          
          5        ASSIGN                                                       !1, $3
   13     6        INIT_METHOD_CALL                                             !1, 'fwrite'
          7        SEND_VAR_EX                                                  !0
          8        DO_FCALL                                          0          
   14     9        INIT_METHOD_CALL                                             !1, 'seek'
         10        SEND_VAL_EX                                                  1
         11        DO_FCALL                                          0          
   15    12        INIT_FCALL                                                   'print_r'
         13        INIT_METHOD_CALL                                             !1, 'fgetcsv'
         14        DO_FCALL                                          0  $8      
         15        SEND_VAR                                                     $8
         16        DO_ICALL                                                     
         17      > RETURN                                                       1

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
159.85 ms | 2594 KiB | 14 Q