3v4l.org

run code in 300+ PHP versions simultaneously
<?php trait T { private $a = 1; public $pa = 1; public function t() { var_dump($this->a); var_dump(get_object_vars($this)); } } class B { private $d = 0; protected $e = 6; public $f = 'sure'; } class A extends B { use T; private $b = 4; public $c = 'hi'; } $a = new A(); $a->t();
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sdvLV
function name:  (null)
number of ops:  7
compiled vars:  !0 = $a
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   19     0  E >   DECLARE_CLASS                                            'a', 'b'
   27     1        NEW                                              $1      'A'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $1
   28     4        INIT_METHOD_CALL                                         !0, 't'
          5        DO_FCALL                                      0          
          6      > RETURN                                                   1

Class T:
Function t:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/sdvLV
function name:  t
number of ops:  12
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   INIT_FCALL                                               'var_dump'
          1        FETCH_OBJ_R                                      ~0      'a'
          2        SEND_VAL                                                 ~0
          3        DO_ICALL                                                 
    9     4        INIT_FCALL                                               'var_dump'
          5        INIT_FCALL                                               'get_object_vars'
          6        FETCH_THIS                                       ~2      
          7        SEND_VAL                                                 ~2
          8        DO_ICALL                                         $3      
          9        SEND_VAR                                                 $3
         10        DO_ICALL                                                 
   10    11      > RETURN                                                   null

End of function t

End of class T.

Class B: [no user functions]
Class A: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.69 ms | 1386 KiB | 17 Q