3v4l.org

run code in 300+ PHP versions simultaneously
<?php function example($foo) { print $foo; } // Prints ``, nothing. example(null); // Prints `1`, boolean is cast to integer and cast to a string. example(true); // Prints `0` example(0); // Fatal error: Object of class stdClass could not be converted to string. example(new \stdClass);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Ih38v
function name:  (null)
number of ops:  15
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'example'
          1        SEND_VAL                                                 null
          2        DO_FCALL                                      0          
   12     3        INIT_FCALL                                               'example'
          4        SEND_VAL                                                 <true>
          5        DO_FCALL                                      0          
   15     6        INIT_FCALL                                               'example'
          7        SEND_VAL                                                 0
          8        DO_FCALL                                      0          
   18     9        INIT_FCALL                                               'example'
         10        NEW                                              $3      'stdClass'
         11        DO_FCALL                                      0          
         12        SEND_VAR                                                 $3
         13        DO_FCALL                                      0          
         14      > RETURN                                                   1

Function example:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/Ih38v
function name:  example
number of ops:  3
compiled vars:  !0 = $foo
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    5     1        ECHO                                                     !0
    6     2      > RETURN                                                   null

End of function example

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
139.19 ms | 1445 KiB | 17 Q