3v4l.org

run code in 300+ PHP versions simultaneously
<?php class DataStorage { use DataHandler; static private $dataStorage = [ 'key' => 'data' ]; } trait DataHandler { static public function get($property) { return self::$dataStorage[$property]; } } echo DataStorage::get('key');
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/FOTob
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   DECLARE_CLASS                                            'datastorage'
   15     1        INIT_STATIC_METHOD_CALL                                  'DataStorage', 'get'
          2        SEND_VAL_EX                                              'key'
          3        DO_FCALL                                      0  $0      
          4        ECHO                                                     $0
          5      > RETURN                                                   1

Class DataStorage: [no user functions]
Class DataHandler:
Function get:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/FOTob
function name:  get
number of ops:  5
compiled vars:  !0 = $property
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
   11     1        FETCH_STATIC_PROP_R          unknown             ~1      'dataStorage'
          2        FETCH_DIM_R                                      ~2      ~1, !0
          3      > RETURN                                                   ~2
   12     4*     > RETURN                                                   null

End of function get

End of class DataHandler.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.05 ms | 1393 KiB | 13 Q