typetools / typetools/checker-framework

Add a constant propagation analysis to dataflow

Open
#4,546 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Performance
Dominant language
Java
Stars
1.1k
Forks
440
Avg merge
1d 12h
Merged PRs (30d)
134

Description

It's slow for other checkers to use the Value Checker to constant values. (The Value Checker has to recompute the type and possible run the dataflow analysis again.) We could write a light weight constant propagation analysis in dataflow that could be used by any checkers. The analysis could trust explicit Value Checker annotations.

(There's already one written: org.checkerframework.dataflow.constantpropagation.ConstantPropagationTransfer, but it's not documented.)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading org.checkerframework.dataflow.constantpropagation.ConstantPropagationTransfer, the existing but undocumented implementation named in the issue. Trace how it can be exposed for reuse by other checkers and how explicit Value Checker annotations should be trusted. Done means a lightweight, documented constant-propagation analysis that avoids recomputing the Value Checker’s analysis.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
devtools
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.