3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace Sample; var_dump(is_resource(STDOUT)); function f1($f) { fwrite($f, "1 called!\n"); } function f2(resource $f) { fwrite($f, "2 called!\n"); } function f3(resource $f) { fwrite($f, "3 called!\n"); } f1(STDOUT); f2(STDOUT); f3(STDOUT);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TjVWS
function name:  (null)
number of ops:  20
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   INIT_NS_FCALL_BY_NAME                                    'Sample%5Cvar_dump'
          1        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cis_resource'
          2        FETCH_CONSTANT                                   ~0      'Sample%5CSTDOUT'
          3        SEND_VAL_EX                                              ~0
          4        DO_FCALL                                      0  $1      
          5        SEND_VAR_NO_REF_EX                                       $1
          6        DO_FCALL                                      0          
   19     7        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cf1'
          8        FETCH_CONSTANT                                   ~3      'Sample%5CSTDOUT'
          9        SEND_VAL_EX                                              ~3
         10        DO_FCALL                                      0          
   20    11        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cf2'
         12        FETCH_CONSTANT                                   ~5      'Sample%5CSTDOUT'
         13        SEND_VAL_EX                                              ~5
         14        DO_FCALL                                      0          
   21    15        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cf3'
         16        FETCH_CONSTANT                                   ~7      'Sample%5CSTDOUT'
         17        SEND_VAL_EX                                              ~7
         18        DO_FCALL                                      0          
         19      > RETURN                                                   1

Function sample%5Cf1:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TjVWS
function name:  Sample\f1
number of ops:  6
compiled vars:  !0 = $f
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    8     1        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cfwrite'
          2        SEND_VAR_EX                                              !0
          3        SEND_VAL_EX                                              '1+called%21%0A'
          4        DO_FCALL                                      0          
    9     5      > RETURN                                                   null

End of function sample%5Cf1

Function sample%5Cf2:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TjVWS
function name:  Sample\f2
number of ops:  6
compiled vars:  !0 = $f
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E >   RECV                                             !0      
   12     1        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cfwrite'
          2        SEND_VAR_EX                                              !0
          3        SEND_VAL_EX                                              '2+called%21%0A'
          4        DO_FCALL                                      0          
   13     5      > RETURN                                                   null

End of function sample%5Cf2

Function sample%5Cf3:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/TjVWS
function name:  Sample\f3
number of ops:  6
compiled vars:  !0 = $f
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   RECV                                             !0      
   16     1        INIT_NS_FCALL_BY_NAME                                    'Sample%5Cfwrite'
          2        SEND_VAR_EX                                              !0
          3        SEND_VAL_EX                                              '3+called%21%0A'
          4        DO_FCALL                                      0          
   17     5      > RETURN                                                   null

End of function sample%5Cf3

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
160.67 ms | 1403 KiB | 22 Q