3v4l.org

run code in 300+ PHP versions simultaneously
<?php class aaa { private static $tpl = array( 'sb_build_id'=>'', 'sb_build_name'=>'' ); public static $xxx = 'aaa'; function yyy(){ echo self::$xxx; } function genprops(){ foreach ($this->dbe as $k => $v) { echo $v; $this->$k = $v; } $this->a = "a"; print_r(get_class_vars(__CLASS__)); } } class ccc extends aaa { public $zzz=''; } class bbb extends ccc { /** * */ function tests(){ parent::$xxx = "bbb"; //echo $this->xxx; echo parent::$xxx; } } $aaa_o = new aaa(); $bbb_o = new bbb(); $bbb_o->yyy(); $bbb_o->tests(); #$bbb_o->genprops(); ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nX5U3
function name:  (null)
number of ops:  11
compiled vars:  !0 = $aaa_o, !1 = $bbb_o
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   43     0  E >   NEW                                              $2      'aaa'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $2
   44     3        NEW                                              $5      'bbb'
          4        DO_FCALL                                      0          
          5        ASSIGN                                                   !1, $5
   45     6        INIT_METHOD_CALL                                         !1, 'yyy'
          7        DO_FCALL                                      0          
   46     8        INIT_METHOD_CALL                                         !1, 'tests'
          9        DO_FCALL                                      0          
   50    10      > RETURN                                                   1

Class aaa:
Function yyy:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nX5U3
function name:  yyy
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   FETCH_STATIC_PROP_R          unknown             ~0      'xxx'
          1        ECHO                                                     ~0
   14     2      > RETURN                                                   null

End of function yyy

Function genprops:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 8
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/nX5U3
function name:  genprops
number of ops:  18
compiled vars:  !0 = $v, !1 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   FETCH_OBJ_R                                      ~2      'dbe'
          1      > FE_RESET_R                                       $3      ~2, ->8
          2    > > FE_FETCH_R                                       ~4      $3, !0, ->8
          3    >   ASSIGN                                                   !1, ~4
   18     4        ECHO                                                     !0
   19     5        ASSIGN_OBJ                                               !1
          6        OP_DATA                                                  !0
   17     7      > JMP                                                      ->2
          8    >   FE_FREE                                                  $3
   21     9        ASSIGN_OBJ                                               'a'
         10        OP_DATA                                                  'a'
   22    11        INIT_FCALL                                               'print_r'
         12        INIT_FCALL                                               'get_class_vars'
         13        SEND_VAL                                                 'aaa'
         14        DO_ICALL                                         $8      
         15        SEND_VAR                                                 $8
         16        DO_ICALL                                                 
   23    17      > RETURN                                                   null

End of function genprops

End of class aaa.

Class ccc:
Function yyy:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nX5U3
function name:  yyy
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   12     0  E >   FETCH_STATIC_PROP_R          unknown             ~0      'xxx'
          1        ECHO                                                     ~0
   14     2      > RETURN                                                   null

End of function yyy

Function genprops:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 8
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/nX5U3
function name:  genprops
number of ops:  18
compiled vars:  !0 = $v, !1 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   FETCH_OBJ_R                                      ~2      'dbe'
          1      > FE_RESET_R                                       $3      ~2, ->8
          2    > > FE_FETCH_R                                       ~4      $3, !0, ->8
          3    >   ASSIGN                                                   !1, ~4
   18     4        ECHO                                                     !0
   19     5        ASSIGN_OBJ                                               !1
          6        OP_DATA                                                  !0
   17     7      > JMP                                                      ->2
          8    >   FE_FREE                                                  $3
   21     9        ASSIGN_OBJ                                               'a'
         10        OP_DATA                                                  'a'
   22    11        INIT_FCALL                                               'print_r'
         12        INIT_FCALL                                               'get_class_vars'
         13        SEND_VAL                                                 'aaa'
         14        DO_ICALL                                         $8      
         15        SEND_VAR                                                 $8
         16        DO_ICALL                                                 
   23    17      > RETURN                                                   null

End of function genprops

End of class ccc.

Class bbb:
Function tests:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/nX5U3
function name:  tests
number of ops:  5
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   36     0  E >   ASSIGN_STATIC_PROP                                       'xxx'
          1        OP_DATA                                                  'bbb'
   38     2        FETCH_STATIC_PROP_R          unknown             ~1      'xxx'
          3        ECHO                                                     ~1
   40     4      > RETURN                                                   null

End of function tests

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

End of function yyy

Function genprops:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 2, Position 2 = 8
Branch analysis from position: 2
2 jumps found. (Code = 78) Position 1 = 3, Position 2 = 8
Branch analysis from position: 3
1 jumps found. (Code = 42) Position 1 = 2
Branch analysis from position: 2
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 8
filename:       /in/nX5U3
function name:  genprops
number of ops:  18
compiled vars:  !0 = $v, !1 = $k
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   FETCH_OBJ_R                                      ~2      'dbe'
          1      > FE_RESET_R                                       $3      ~2, ->8
          2    > > FE_FETCH_R                                       ~4      $3, !0, ->8
          3    >   ASSIGN                                                   !1, ~4
   18     4        ECHO                                                     !0
   19     5        ASSIGN_OBJ                                               !1
          6        OP_DATA                                                  !0
   17     7      > JMP                                                      ->2
          8    >   FE_FREE                                                  $3
   21     9        ASSIGN_OBJ                                               'a'
         10        OP_DATA                                                  'a'
   22    11        INIT_FCALL                                               'print_r'
         12        INIT_FCALL                                               'get_class_vars'
         13        SEND_VAL                                                 'aaa'
         14        DO_ICALL                                         $8      
         15        SEND_VAR                                                 $8
         16        DO_ICALL                                                 
   23    17      > RETURN                                                   null

End of function genprops

End of class bbb.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
162.12 ms | 1404 KiB | 17 Q