3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Any { private bool $bRequired = false; public function __construct(?bool $bRequired, string $sREquired) {} public function setBRequired($bRequired) { $this->bRequired = $bRequired; } public function getBRequired() { return $this->bRequired; } } $r = new ReflectionClass(Any::class); $i = $r->newinstancewithoutconstructor(); var_dump($i->getBRequired()); $i->setBRequired(true); var_dump($i->getBRequired());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hK2ZR
function name:  (null)
number of ops:  21
compiled vars:  !0 = $r, !1 = $i
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   21     0  E >   NEW                                              $2      'ReflectionClass'
          1        SEND_VAL_EX                                              'Any'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !0, $2
   23     4        INIT_METHOD_CALL                                         !0, 'newinstancewithoutconstructor'
          5        DO_FCALL                                      0  $5      
          6        ASSIGN                                                   !1, $5
   24     7        INIT_FCALL                                               'var_dump'
          8        INIT_METHOD_CALL                                         !1, 'getBRequired'
          9        DO_FCALL                                      0  $7      
         10        SEND_VAR                                                 $7
         11        DO_ICALL                                                 
   26    12        INIT_METHOD_CALL                                         !1, 'setBRequired'
         13        SEND_VAL_EX                                              <true>
         14        DO_FCALL                                      0          
   28    15        INIT_FCALL                                               'var_dump'
         16        INIT_METHOD_CALL                                         !1, 'getBRequired'
         17        DO_FCALL                                      0  $10     
         18        SEND_VAR                                                 $10
         19        DO_ICALL                                                 
         20      > RETURN                                                   1

Class Any:
Function __construct:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hK2ZR
function name:  __construct
number of ops:  3
compiled vars:  !0 = $bRequired, !1 = $sREquired
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    7     0  E >   RECV                                             !0      
          1        RECV                                             !1      
    8     2      > RETURN                                                   null

End of function __construct

Function setbrequired:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hK2ZR
function name:  setBRequired
number of ops:  4
compiled vars:  !0 = $bRequired
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   10     0  E >   RECV                                             !0      
   12     1        ASSIGN_OBJ                                               'bRequired'
          2        OP_DATA                                                  !0
   13     3      > RETURN                                                   null

End of function setbrequired

Function getbrequired:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/hK2ZR
function name:  getBRequired
number of ops:  3
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   FETCH_OBJ_R                                      ~0      'bRequired'
          1      > RETURN                                                   ~0
   18     2*     > RETURN                                                   null

End of function getbrequired

End of class Any.

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
143.6 ms | 1431 KiB | 14 Q