ext/reflection: Add `getFqn()` method to `ReflectionClass`, `ReflectionConstant`, `ReflectionFunctionAbstract`, and `ReflectionAttribute`
Open
@DanielEScherzer is already working on this.
Since Aug 23, 2025.
Extension: reflection
Feature
- Dominant language
- C
- Stars
- 40.4k
- Forks
- 8.1k
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 96
Description
Description
The getName() method on those classes returns a qualified name 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.
This maybe also should be added to ReflectionClassConstant as methods would also have this new method automatically due to ReflectionMethod inheriting from ReflectionFunctionAbstract.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.