3v4l.org

run code in 300+ PHP versions simultaneously
<?php function my_autoloader($class) { include 'classes/' . $class . '.class.php'; } spl_autoload_register('my_autoloader'); // Or, using an anonymous function as of PHP 5.3.0 spl_autoload_register(function ($class) { include 'classes/' . $class . '.class.php'; });
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/HOvPF
function name:  (null)
number of ops:  8
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   INIT_FCALL                                               'spl_autoload_register'
          1        SEND_VAL                                                 'my_autoloader'
          2        DO_ICALL                                                 
    9     3        INIT_FCALL                                               'spl_autoload_register'
          4        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FHOvPF%3A9%240'
   11     5        SEND_VAL                                                 ~1
          6        DO_ICALL                                                 
          7      > RETURN                                                   1

Function my_autoloader:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/HOvPF
function name:  my_autoloader
number of ops:  5
compiled vars:  !0 = $class
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   RECV                                             !0      
    3     1        CONCAT                                           ~1      'classes%2F', !0
          2        CONCAT                                           ~2      ~1, '.class.php'
          3        INCLUDE_OR_EVAL                                          ~2, INCLUDE
    4     4      > RETURN                                                   null

End of function my_autoloader

Function %00%7Bclosure%7D%2Fin%2FHOvPF%3A9%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/HOvPF
function name:  {closure}
number of ops:  5
compiled vars:  !0 = $class
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   RECV                                             !0      
   10     1        CONCAT                                           ~1      'classes%2F', !0
          2        CONCAT                                           ~2      ~1, '.class.php'
          3        INCLUDE_OR_EVAL                                          ~2, INCLUDE
   11     4      > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FHOvPF%3A9%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
166.43 ms | 1395 KiB | 15 Q