3v4l.org

run code in 300+ PHP versions simultaneously
<?php $omaluokka = new class('Matti') { private $name; function __construct($name) { $this->name = $name; } public function whois() { return $this->name; } }; var_dump($omaluokka->whois());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CQMPF
function name:  (null)
number of ops:  11
compiled vars:  !0 = $omaluokka
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   DECLARE_ANON_CLASS                               <undef> 
          1        NEW                                              $2      $1
          2        SEND_VAL_EX                                              'Matti'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !0, $2
   17     5        INIT_FCALL                                               'var_dump'
          6        INIT_METHOD_CALL                                         !0, 'whois'
          7        DO_FCALL                                      0  $5      
          8        SEND_VAR                                                 $5
          9        DO_ICALL                                                 
         10      > RETURN                                                   1

Class class@anonymous:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CQMPF
function name:  __construct
number of ops:  4
compiled vars:  !0 = $name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    6     0  E >   RECV                                             !0      
    8     1        ASSIGN_OBJ                                               'name'
          2        OP_DATA                                                  !0
    9     3      > RETURN                                                   null

End of function __construct

Function whois:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/CQMPF
function name:  whois
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   13     0  E >   FETCH_OBJ_R                                      ~0      'name'
          1      > RETURN                                                   ~0
   14     2*     > RETURN                                                   null

End of function whois

End of class class@anonymous.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
165.44 ms | 1395 KiB | 15 Q