3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Test { public stdClass $prop; } $rp = new ReflectionProperty(Test::class, 'prop'); $test = new Test; $test->prop = new stdClass; var_dump($rp->getType()->getName());

This is an error 500

Value for `_results` contains invalid data `array`


preferences:
159.43 ms | 3360 KiB | 9 Q