phpDocumentor / phpDocumentor/ReflectionDocBlock
Location information for tags
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 9.4k
- Forks
- 137
- Avg merge
- 4d 2h
- Merged PRs (30d)
- 1
Description
I am using this package in the open PHP language server, which provides static analysis for any IDE through the open language server protocol. One of these features is "Go to Definition". This is currently implemented for the actual PHP code through nikic's great PHPParser, where every node has a file start/end offset so I can calculate which node the user clicked. It would be nice to have this feature for types in docblock tags like @var too, but the tags don't have any start/end offset data. Would it be possible to add this?
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.
Research direction
No files or tests are named in the issue. Start by locating how @var and other docblock tags are parsed and compare their metadata with PHPParser nodes. Define how tag start and end offsets should be exposed, then verify that type tags provide usable location information without breaking existing parsing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100