- print_r: documentation ( source)
<?php declare(strict_types = 1);
#[\AllowDynamicProperties]
class Cl {
}
print_r((new ReflectionClass(Cl::class))->getAttributes());
class Cl2 {
public $p;
}
print_r((new ReflectionClass(Cl2::class))->getProperties());