3v4l.org

run code in 300+ PHP versions simultaneously
<?php $s = fopen('php://memory', 'w'); var_dump($s, is_resource($s), gettype($s)); fclose($s); var_dump($s, is_resource($s), gettype($s));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/qnk41
function name:  (null)
number of ops:  23
compiled vars:  !0 = $s
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'
          3        DO_ICALL                                         $1      
          4        ASSIGN                                                   !0, $1
    4     5        INIT_FCALL                                               'var_dump'
          6        SEND_VAR                                                 !0
          7        TYPE_CHECK                                  512  ~3      !0
          8        SEND_VAL                                                 ~3
          9        GET_TYPE                                         ~4      !0
         10        SEND_VAL                                                 ~4
         11        DO_ICALL                                                 
    5    12        INIT_FCALL                                               'fclose'
         13        SEND_VAR                                                 !0
         14        DO_ICALL                                                 
    6    15        INIT_FCALL                                               'var_dump'
         16        SEND_VAR                                                 !0
         17        TYPE_CHECK                                  512  ~7      !0
         18        SEND_VAL                                                 ~7
         19        GET_TYPE                                         ~8      !0
         20        SEND_VAL                                                 ~8
         21        DO_ICALL                                                 
         22      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
139.91 ms | 999 KiB | 16 Q