[php-src] Issue #19558: ext/reflection: Add `getFqn()` method to `ReflectionClass`, `ReflectionConstant`, `ReflectionFunctionAbstract`, and
`ReflectionAttribute`
| From: | Girgias | Date: | Fri, 22 Aug 2025 17:19:56 +0000 |
| Subject: | [php-src] Issue #19558: ext/reflection: Add `getFqn()` method to `ReflectionClass`, `ReflectionConstant`, `ReflectionFunctionAbstract`, and `ReflectionAttribute` |
||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-250609@lists.php.net to get a copy of this message | ||
Issue: https://github.com/php/php-src/issues/19558
Author: Girgias
### Description
The
getName() method on those classes returns a [qualified
name](https://www.php.net/manual/en/language.namespaces.rules.php) rather than the fully qualified
name.
There are various instances where just a qualified name is not sufficient (e.g. documentation or
code gen), and while it is very easy to get the FQN by just prepending \ to the name
from getName() this is something that needs to be known to be safe to do.