3v4l.org

run code in 500+ PHP versions simultaneously
<?php class AbstractDomainObject { private $private; protected $protected; } class Entity extends AbstractDomainObject { public function propertyExists(string $propertyName): bool { return property_exists($this, $propertyName); } } var_dump((new Entity())->propertyExists('private')); var_dump((new Entity())->propertyExists('protected'));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/T37NR
function name:  (null)
number of ops:  17
compiled vars:  none
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   16     0  E >   INIT_FCALL                                                   'var_dump'
          1        NEW                                                  $0      'Entity'
          2        DO_FCALL                                          0          
          3        INIT_METHOD_CALL                                             $0, 'propertyExists'
          4        SEND_VAL_EX                                                  'private'
          5        DO_FCALL                                          0  $2      
          6        SEND_VAR                                                     $2
          7        DO_ICALL                                                     
   17     8        INIT_FCALL                                                   'var_dump'
          9        NEW                                                  $4      'Entity'
         10        DO_FCALL                                          0          
         11        INIT_METHOD_CALL                                             $4, 'propertyExists'
         12        SEND_VAL_EX                                                  'protected'
         13        DO_FCALL                                          0  $6      
         14        SEND_VAR                                                     $6
         15        DO_ICALL                                                     
         16      > RETURN                                                       1

Class AbstractDomainObject: [no user functions]
Class Entity:
Function propertyexists:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/T37NR
function name:  propertyExists
number of ops:  7
compiled vars:  !0 = $propertyName
line      #* E I O op                               fetch          ext  return  operands
-----------------------------------------------------------------------------------------
   10     0  E >   RECV                                                 !0      
   12     1        FETCH_THIS                                           ~1      
          2        FRAMELESS_ICALL_2                property_exists      ~2      ~1, !0
          3        VERIFY_RETURN_TYPE                                           ~2
          4      > RETURN                                                       ~2
   13     5*       VERIFY_RETURN_TYPE                                           
          6*     > RETURN                                                       null

End of function propertyexists

End of class Entity.

Generated using Vulcan Logic Dumper, using php 8.5.0


preferences:
137.57 ms | 487 KiB | 12 Q