rewrite-static-analysis icon indicating copy to clipboard operation
rewrite-static-analysis copied to clipboard

`OperatorWrap` and `WrappingAndBraces` causing wrong result for Kotlin

Open SettingDust opened this issue 1 year ago • 1 comments

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.

  1. 图片
  2. 图片

What did you expect to see?

  1. 图片
  2. No

What did you see instead?

  1. 图片
  2. 图片 图片

Are you interested in contributing a fix to OpenRewrite?

No

SettingDust avatar Jun 12 '24 03:06 SettingDust

Thanks for reporting your issue here as well @SettingDust ! Definitely something to fix such that these recipes just work for Kotlin too.

timtebeek avatar Jun 12 '24 07:06 timtebeek