3v4l.org

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

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

End of function __construct

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

End of function hello

End of class Text.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.27 ms | 1386 KiB | 15 Q