bug36308.phpt 473 B

12345678910111213141516171819202122
  1. --TEST--
  2. Reflection Bug #36308 (ReflectionProperty::getDocComment() does not reflect extended class commentary)
  3. --INI--
  4. opcache.save_comments=1
  5. --FILE--
  6. <?php
  7. class Base {
  8. /** Base comment block */
  9. public $foo = 'bar';
  10. }
  11. class Extended extends Base {
  12. /** Extended commentary */
  13. public $foo = 'zim';
  14. }
  15. $reflect = new ReflectionClass('Extended');
  16. $props = $reflect->getProperties();
  17. echo $props[0]->getDocComment();
  18. ?>
  19. --EXPECT--
  20. /** Extended commentary */