3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Foo { private $bar; } $object = (object) ["\0Foo\0bar" => 'tab']; $r = new ReflectionProperty(Foo::class, 'bar'); $r->setAccessible(true); var_dump($r->getValue($object));
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/vCEFt
function name:  (null)
number of ops:  17
compiled vars:  !0 = $object, !1 = $r
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    8     0  E >   CAST                                          8  ~2      <array>
          1        ASSIGN                                                   !0, ~2
   10     2        NEW                                              $4      'ReflectionProperty'
          3        SEND_VAL_EX                                              'Foo'
          4        SEND_VAL_EX                                              'bar'
          5        DO_FCALL                                      0          
          6        ASSIGN                                                   !1, $4
   12     7        INIT_METHOD_CALL                                         !1, 'setAccessible'
          8        SEND_VAL_EX                                              <true>
          9        DO_FCALL                                      0          
   14    10        INIT_FCALL                                               'var_dump'
         11        INIT_METHOD_CALL                                         !1, 'getValue'
         12        SEND_VAR_EX                                              !0
         13        DO_FCALL                                      0  $8      
         14        SEND_VAR                                                 $8
         15        DO_ICALL                                                 
         16      > RETURN                                                   1

Class Foo: [no user functions]

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
124.42 ms | 999 KiB | 14 Q