3v4l.org

run code in 300+ PHP versions simultaneously
<?php namespace Milkway\Earth; class Human{} namespace Universe; $human = new \Milkway\Earth\Human(); echo get_class($human) . PHP_EOL; $class = str_replace('Earth\\', '', get_class($human)); echo $class;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/fKSjY
function name:  (null)
number of ops:  20
compiled vars:  !0 = $human, !1 = $class
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   NEW                                              $2      'Milkway%5CEarth%5CHuman'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
    9     3        INIT_NS_FCALL_BY_NAME                                    'Universe%5Cget_class'
          4        SEND_VAR_EX                                              !0
          5        DO_FCALL                                      0  $5      
          6        FETCH_CONSTANT                                   ~6      'Universe%5CPHP_EOL'
          7        CONCAT                                           ~7      $5, ~6
          8        ECHO                                                     ~7
   11     9        INIT_NS_FCALL_BY_NAME                                    'Universe%5Cstr_replace'
         10        SEND_VAL_EX                                              'Earth%5C'
         11        SEND_VAL_EX                                              ''
         12        INIT_NS_FCALL_BY_NAME                                    'Universe%5Cget_class'
         13        SEND_VAR_EX                                              !0
         14        DO_FCALL                                      0  $8      
         15        SEND_VAR_NO_REF_EX                                       $8
         16        DO_FCALL                                      0  $9      
         17        ASSIGN                                                   !1, $9
   13    18        ECHO                                                     !1
         19      > RETURN                                                   1

Class Milkway\Earth\Human: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
163.6 ms | 1395 KiB | 17 Q