Skip to content

fix(xtext): extend the counter warning suppression to removeMappings' visitor - #1574

Merged
joaodinissf merged 1 commit into
masterfrom
fix/spotbugs-4.10.5-false-positives
Oct 19, 2026
Merged

joaodinissf merged 1 commit into
masterfrom
fix/spotbugs-4.10.5-false-positives

Conversation

@joaodinissf

Copy link
Copy Markdown
Collaborator

Why the change

The SpotBugs 4.10.5 bump (#1572) still fails, on the second and last new finding: AT_NONATOMIC_OPERATIONS_ON_SHARED_VARIABLE for size-- in QualifiedNameSegmentTreeLookup.removeMappings. It is the same accepted pattern #1573 handled: removeMappings already suppresses this warning, as get() does for hits and misses, because the lookup tolerates approximate counters. SpotBugs 4.10.5 attributes the decrement to the anonymous Visitor's visit(), which the outer annotation doesn't cover.

Special things to note

  • visit() gets the same @SuppressFBWarnings as removeMappings; no behaviour change.
  • com.avaloq.tools.ddk.xtext goes to 17.4.3, since 17.4.2 was released in 19.3.0. The features are already at 19.3.1 on master.
  • No more findings after this one: a full-reactor run of SpotBugs 4.10.5 (spotbugs:spotbugs in all 56 analysed modules, so no module is skipped after an earlier failure) reported only this one. With this change, a full local build with SpotBugs 4.10.5 and spotbugs:check, checkstyle, PMD/CPD and the release version check passes.
  • After this merges, chore(deps): bump com.github.spotbugs:spotbugs from 4.10.4 to 4.10.5 in /ddk-parent #1572 needs a rebase to pick it up.

🤖 Generated with Claude Code

… visitor

SpotBugs 4.10.5 reports AT_NONATOMIC_OPERATIONS_ON_SHARED_VARIABLE for
size-- in QualifiedNameSegmentTreeLookup.removeMappings. removeMappings
already suppresses it, as get() does for hits and misses, because the
lookup accepts approximate counters; 4.10.5 attributes the decrement to
the anonymous Visitor's visit(), which the outer annotation doesn't
cover. Annotate visit() the same way. A full-reactor run of SpotBugs
4.10.5 reports no other finding, so this unblocks the SpotBugs bump
(#1572). Bump the bundle to 17.4.3, since 17.4.2 was released in 19.3.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@joaodinissf
joaodinissf marked this pull request as ready for review October 17, 2026 08:55
@joaodinissf
joaodinissf enabled auto-merge October 17, 2026 09:01
@joaodinissf
joaodinissf added this pull request to the merge queue Oct 19, 2026
Merged via the queue into master with commit 6fca492 Oct 19, 2026
4 checks passed
@joaodinissf
joaodinissf deleted the fix/spotbugs-4.10.5-false-positives branch October 19, 2026 07:27
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