3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Device { public function getDeviceModel() { return new DeviceModel(); } } class DeviceModel { public function getResetManualAllowed(){ return true; } } $device = new Device(); if($device->getDeviceModel()->getResetManualAllowed()) { echo "allowed"; } echo "nix";
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 8, Position 2 = 9
Branch analysis from position: 8
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 9
filename:       /in/cB8kR
function name:  (null)
number of ops:  11
compiled vars:  !0 = $device
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   NEW                                              $1      'Device'
          1        DO_FCALL                                      0          
          2        ASSIGN                                                   !0, $1
   17     3        INIT_METHOD_CALL                                         !0, 'getDeviceModel'
          4        DO_FCALL                                      0  $4      
          5        INIT_METHOD_CALL                                         $4, 'getResetManualAllowed'
          6        DO_FCALL                                      0  $5      
          7      > JMPZ                                                     $5, ->9
   18     8    >   ECHO                                                     'allowed'
   20     9    >   ECHO                                                     'nix'
         10      > RETURN                                                   1

Class Device:
Function getdevicemodel:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/cB8kR
function name:  getDeviceModel
number of ops:  4
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   NEW                                              $0      'DeviceModel'
          1        DO_FCALL                                      0          
          2      > RETURN                                                   $0
    6     3*     > RETURN                                                   null

End of function getdevicemodel

End of class Device.

Class DeviceModel:
Function getresetmanualallowed:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/cB8kR
function name:  getResetManualAllowed
number of ops:  2
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   11     0  E > > RETURN                                                   <true>
   12     1*     > RETURN                                                   null

End of function getresetmanualallowed

End of class DeviceModel.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.81 ms | 1394 KiB | 13 Q