Phan should support typing the values of classes that implement Traversable
Open
Nobody has claimed this yet.
enhancement
- Dominant language
- PHP
- Stars
- 5.6k
- Forks
- 365
- Avg merge
- 1h 25m
- Merged PRs (30d)
- 6
Description
For example: https://gist.github.com/dasl-/3043063db918e189c705788877b4720c
Would be great if phan could support typing like * @param MyData<I> $data for classes that implement Traversable. I realize that Traversable<I> is already supported.
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
Start with the linked gist and the existing support for Traversable<I> to understand the requested MyData<I> behavior. Determine the affected type-inference paths and add coverage showing that classes implementing Traversable preserve the value type in annotations; done means the example is correctly accepted and analyzed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100