3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { } $a = new Foo; $class = 'Foo'; $b = new $class; $class = ucfirst('foo'); $c = new $class;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/mrSff
function name:  (null)
number of ops:  17
compiled vars:  !0 = $a, !1 = $class, !2 = $b, !3 = $c
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   NEW                                              $4      'Foo'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $4
   10     3        ASSIGN                                                   !1, 'Foo'
   11     4        FETCH_CLASS                                   0  $8      !1
          5        NEW                                              $9      $8
          6        DO_FCALL                                      0          
          7        ASSIGN                                                   !2, $9
   13     8        INIT_FCALL                                               'ucfirst'
          9        SEND_VAL                                                 'foo'
         10        DO_ICALL                                         $12     
         11        ASSIGN                                                   !1, $12
   14    12        FETCH_CLASS                                   0  $14     !1
         13        NEW                                              $15     $14
         14        DO_FCALL                                      0          
         15        ASSIGN                                                   !3, $15
         16      > RETURN                                                   1

Class Foo: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.37 ms | 1068 KiB | 14 Q