typetools / typetools/checker-framework
`JavaExpression` for type casts
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.1k
- Forks
- 440
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 134
Description
Currently, there's no subtype of JavaExpression that corresponds CFG's TypeCastNode.
In our current application, type casts are transparent to the checker so we just unwrap the type cast nodes (although I can see that down the line we may want to handle type casts differently). In order to properly unwrap type-casts, we had to extract 3 mutually recursive functions fromNode/fromNodeFieldAccess/fromArrayAccess and patch them a bit.
Not a big problem, but I was wondering if there's a reason the current JavaExpression hierarchy doesn't have a TypeCast?
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 reading the JavaExpression hierarchy and CFG's TypeCastNode, then examine the mutually recursive fromNode, fromNodeFieldAccess, and fromArrayAccess functions described in the issue. Determine whether adding a TypeCast expression fits the existing model and what behavior should be preserved when type casts are unwrapped.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- compilers, devtools
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100