typetools / typetools/checker-framework
Separate type parameter declaration from type variable use
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.1k
- Forks
- 440
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 134
Description
AnnotatedTypeMirror.isDeclaration currently indicates this distinction.
It would be nicer to have a separate AnnotatedTypeParameter class that is NOT a subtype of AnnotatedTypeMirror. We could then remove AnnotatedTypeMirror.isDeclaration and use AnnotatedTypeParameter where appropriate.
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 by inspecting AnnotatedTypeMirror.isDeclaration and all usages of that distinction in the Checker Framework. Trace how type parameter declarations and type variable uses are represented, then determine the affected APIs and tests. Done means the separate AnnotatedTypeParameter abstraction replaces the distinction and AnnotatedTypeMirror.isDeclaration can be removed without breaking the relevant behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- compilers
- Issue type
- Refactor
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100