Skip to content

Rename arraysAreRelevant to arrayTypesAreRelevant - #8174

Merged
smillst merged 2 commits into
typetools:masterfrom
mernst:rename-array-types-are-relevant
Sep 16, 2026
Merged

smillst merged 2 commits into
typetools:masterfrom
mernst:rename-array-types-are-relevant

Conversation

@mernst

@mernst mernst commented Sep 15, 2026 •

Copy link
Copy Markdown
Member

GenericAnnotatedTypeFactory.arraysAreRelevant is about array types, so rename it to arrayTypesAreRelevant and add a public accessor. Its documentation described when isRelevantImpl happens to consult it; document its value directly instead.

Also document what an override of isRelevantImpl must handle: the implementation in GenericAnnotatedTypeFactory returns true immediately for the types in relevantJavaTypes, and for every type when relevantJavaTypes == null, so an override must handle those cases itself or call super.

The renamed field is protected, so this is a source-incompatible change for a type system outside this repository; the changelog records it. No type system in this repository referred to the old name.

🤖 Generated with Claude Code

The field is about array *types*, so name it accordingly.  Add a public
accessor for it, and document its value directly rather than describing when
`isRelevantImpl` happens to consult it.

Also document what an override of `isRelevantImpl` must handle: the cases for
which the implementation in `GenericAnnotatedTypeFactory` returns true
immediately.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Sep 15, 2026 •

Copy link
Copy Markdown
Contributor

Review Change StackReview Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 3333045d-1df7-4997-8d26-52a25b48fe62

📥 Commits

Reviewing files that changed from the base of the PR and between b87c803 and 4bbd6f9.

📒 Files selected for processing (2)
  • docs/CHANGELOG.md
  • framework/src/main/java/org/checkerframework/framework/type/GenericAnnotatedTypeFactory.java

Included review availability: Your plan provides up to 4 included reviews per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

GenericAnnotatedTypeFactory renames arraysAreRelevant to arrayTypesAreRelevant. Constructor initialization, array relevance checks, and diagnostic messages use the renamed field. The class adds a public arrayTypesAreRelevant() accessor. Javadocs and the version 4.2.4 changelog document the API change.

Suggested reviewers: smillst

Priority: ⬇️ Low

Change: Refactor

Merge Risk: ⚪ Minimal · up to 49c01

The API rename is documented and does not introduce an unresolved repository risk, so the change is ready to merge.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 1 files. (1 skipped: 1 …
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@smillst
smillst merged commit cdc17d2 into typetools:master Sep 16, 2026
27 checks passed
@smillst
smillst deleted the rename-array-types-are-relevant branch September 16, 2026 15:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants