3v4l.org

run code in 300+ PHP versions simultaneously
<?php class A { const A = 'a'; } class RefProp extends \ReflectionProperty { public function __construct($class, $name) { } } $ref = new RefProp('A', 'A'); var_dump($ref::IS_PUBLIC);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/k5d7F
function name:  (null)
number of ops:  11
compiled vars:  !0 = $ref
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   15     0  E >   NEW                                              $1      'RefProp'
          1        SEND_VAL_EX                                              'A'
          2        SEND_VAL_EX                                              'A'
          3        DO_FCALL                                      0          
          4        ASSIGN                                                   !0, $1
   17     5        INIT_FCALL                                               'var_dump'
          6        FETCH_CLASS                                   0  $4      !0
          7        FETCH_CLASS_CONSTANT                             ~5      $4, 'IS_PUBLIC'
          8        SEND_VAL                                                 ~5
          9        DO_ICALL                                                 
         10      > RETURN                                                   1

Class A: [no user functions]
Class RefProp:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/k5d7F
function name:  __construct
number of ops:  3
compiled vars:  !0 = $class, !1 = $name
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
          1        RECV                                             !1      
   12     2      > RETURN                                                   null

End of function __construct

End of class RefProp.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
147.4 ms | 939 KiB | 16 Q