3v4l.org

run code in 300+ PHP versions simultaneously
<?php function lol($class) { eval('class '.$class.' {}'); echo "Bon, j'ai créé la classe ".$class."\n"; } spl_autoload_register('lol'); $fooA = new foo(); $fooB = new foo(); $barA = new bar();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bvRls
function name:  (null)
number of ops:  13
compiled vars:  !0 = $fooA, !1 = $fooB, !2 = $barA
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    9     0  E >   INIT_FCALL                                               'spl_autoload_register'
          1        SEND_VAL                                                 'lol'
          2        DO_ICALL                                                 
   11     3        NEW                                              $4      'foo'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !0, $4
   12     6        NEW                                              $7      'foo'
          7        DO_FCALL                                      0          
          8        ASSIGN                                                   !1, $7
   13     9        NEW                                              $10     'bar'
         10        DO_FCALL                                      0          
         11        ASSIGN                                                   !2, $10
         12      > RETURN                                                   1

Function lol:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/bvRls
function name:  lol
number of ops:  8
compiled vars:  !0 = $class
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   RECV                                             !0      
    4     1        CONCAT                                           ~1      'class+', !0
          2        CONCAT                                           ~2      ~1, '+%7B%7D'
          3        INCLUDE_OR_EVAL                                          ~2, EVAL
    5     4        CONCAT                                           ~4      'Bon%2C+j%27ai+cr%C3%A9%C3%A9+la+classe+', !0
          5        CONCAT                                           ~5      ~4, '%0A'
          6        ECHO                                                     ~5
    6     7      > RETURN                                                   null

End of function lol

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
145.29 ms | 1395 KiB | 15 Q