3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php /** * ClassDocComment * * @copyright Copyright (c) 2011 * @author author * @see http://php.net */ class ClassDocComment { /** * Some Doc comment */ private $comment; } #echo (new ReflectionClass ('ClassDocComment'))->getDocComment(); var_dump ((string) new ReflectionClass ('ClassDocComment'));
based on rIAOT
Output for 5.3.22 - 5.6.28, 7.0.4 - 7.2.0
string(349) "/** * ClassDocComment * * @copyright Copyright (c) 2011 * @author author * @see http://php.net */ Class [ <user> class ClassDocComment ] { @@ /in/HYUT7 10-16 - Constants [0] { } - Static properties [0] { } - Static methods [0] { } - Properties [1] { Property [ <default> private $comment ] } - Methods [0] { } } "
Output for 7.0.0 - 7.0.3
string(247) " Class [ <user> class ClassDocComment ] { @@ /in/HYUT7 10-16 - Constants [0] { } - Static properties [0] { } - Static methods [0] { } - Properties [1] { Property [ <default> private $comment ] } - Methods [0] { } } "