openrewrite / openrewrite/rewrite-static-analysis
`OperatorWrap` and `WrappingAndBraces` causing wrong result for Kotlin
Open
Nobody has claimed this yet.
bug
- Dominant language
- Java
- Stars
- 62
- Forks
- 112
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 40
Description
What version of OpenRewrite are you using?
I am using
- OpenRewrite 8.27.4
- Maven/Gradle plugin 6.16.0
- rewrite-static-analysis 1.9.0
How are you running OpenRewrite?
Gradle.
Single Module
https://github.com/SettingDust/TheAbyss
What is the smallest, simplest way to reproduce the problem?
https://discord.com/channels/996548279191998535/996548280118935674/1249202116883513425
Run the rewrite with gradle.
What did you expect to see?
- No
What did you see instead?
Are you interested in contributing a fix to OpenRewrite?
No
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the report in the linked TheAbyss project with Gradle, focusing on the OperatorWrap and WrappingAndBraces recipes and the two numbered cases shown in the issue. Compare the generated Kotlin with the expected and observed screenshots, then add a regression test for the discrepancy and verify the rewrite no longer produces the reported result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, kotlin
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100