3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $stream = fopen('php://memory', 'w+'); $meta = stream_get_meta_data($stream); var_dump(is_writable($meta['uri']), fwrite($stream, 'foobar'), $meta);
based on 6I40g
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/VsXEJ
function name:  (null)
number of ops:  23
compiled vars:  !0 = $stream, !1 = $meta
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   3     0  E >   INIT_FCALL                                               'fopen'
         1        SEND_VAL                                                 'php%3A%2F%2Fmemory'
         2        SEND_VAL                                                 'w%2B'
         3        DO_ICALL                                         $2      
         4        ASSIGN                                                   !0, $2
   4     5        INIT_FCALL                                               'stream_get_meta_data'
         6        SEND_VAR                                                 !0
         7        DO_ICALL                                         $4      
         8        ASSIGN                                                   !1, $4
   5     9        INIT_FCALL                                               'var_dump'
        10        INIT_FCALL                                               'is_writable'
        11        FETCH_DIM_R                                      $6      !1, 'uri'
        12        SEND_VAR                                                 $6
        13        DO_ICALL                                         $7      
        14        SEND_VAR                                                 $7
        15        INIT_FCALL                                               'fwrite'
        16        SEND_VAR                                                 !0
        17        SEND_VAL                                                 'foobar'
        18        DO_ICALL                                         $8      
        19        SEND_VAR                                                 $8
        20        SEND_VAR                                                 !1
        21        DO_ICALL                                                 
        22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 7.3.0