Skip to content

Fix #5915: [java] Fix AssignmentInOperandRule to also work an do-while loops and switch statements. #5924

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

UncleOwen
Copy link
Contributor

@UncleOwen UncleOwen commented Jul 20, 2025

Describe the PR

This PR fixes the AssignmentInOperandRule so that is works in all cases of assignment inside control statement.
Adds two new properties to the rule: allowDoWhile and allowSwitch.

Related issues

Ready?

  • Added unit tests for fixed bug/feature
  • Passing all unit tests
  • Complete build ./mvnw clean verify passes (checked automatically by github actions)
  • Added (in-code) documentation (if needed)

@UncleOwen UncleOwen changed the title Fix #5915: Fix AssignmentInOperandRule to also work an do-while loops and switch statements. Fix #5915: [java] Fix AssignmentInOperandRule to also work an do-while loops and switch statements. Jul 20, 2025
Copy link

Documentation Preview

Compared to main:
This changeset changes 0 violations,
introduces 127 new violations, 0 new errors and 0 new configuration errors,
removes 0 violations, 25 errors and 8 configuration errors.

Regression Tester Report

(comment created at 2025-07-20 16:46:56+00:00 for 8e8acc0)

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.

[java] AssignmentInOperand not raised when inside do-while loop
1 participant
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy