Skip to content
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

While loop condition spaces #131

Merged
merged 3 commits into from
Jan 24, 2025
Merged

While loop condition spaces #131

merged 3 commits into from
Jan 24, 2025

Conversation

nielsdebruin
Copy link
Contributor

What's changed?

This PR adds a fix and extra test for while loops to the SpaceVisitor, ensuring the while loop conditions have proper spacing.

What's your motivation?

Anything in particular you'd like reviewers to focus on?

Anyone you would like to review specifically?

Have you considered any alternatives or workarounds?

Any additional context

Checklist

  • I've added unit tests to cover both positive and negative cases
  • I've read and applied the recipe conventions and best practices
  • I've used the IntelliJ IDEA auto-formatter on affected files

@nielsdebruin nielsdebruin added bug Something isn't working enhancement New feature or request labels Jan 23, 2025
@nielsdebruin nielsdebruin self-assigned this Jan 23, 2025
@@ -1,6 +1,7 @@
from typing import Optional, cast, List, TypeVar

import rewrite.java as j
from java import WhileLoop
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks strange. I think we should import from rewrite.java like all the others.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@nielsdebruin nielsdebruin merged commit 63c78c7 into main Jan 24, 2025
1 check passed
@nielsdebruin nielsdebruin deleted the fix/spaces-while-loop branch January 24, 2025 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

2 participants