3v4l.org

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

Class Test:
Function attrtest:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/GTnvl
function name:  attrTest
number of ops:  4
compiled vars:  !0 = $attr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
    9     1        FETCH_OBJ_R                                      ~1      !0
          2      > RETURN                                                   ~1
   10     3*     > RETURN                                                   null

End of function attrtest

End of class Test.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
151.08 ms | 1394 KiB | 15 Q