Closed yonatankarp closed 8 months ago
@yonatankarp thanks for reporting the issue. We will look on it
This problem was solved in diktat-1.2.5. Please, move to diktat-2.0.0. However, if you need spotless, then move to diktat-1.2.5.
Thanks @diphtongue ! Seems to solve the problem 🙏
I'm closing the issue
If you're just submitting a feature request or question, no need for the above.
When I'm using an internal functional interface, the formatting puts the
fun
keyword in front of theinternal
keyword causing the code to be un-compileable.For example, the following class:
Will end up as follows after running spotless:
The above code using Spotless Gradle plugin (version
6.22.0
) with this configuration:Here you can see the output log of the issue:
The issue was reported to Spotless and pin-point to
dektat
as can be seen in this Issue: https://github.com/diffplug/spotless/issues/1865A code example that reproduces the issue can be found here: https://github.com/yonatankarp/spotless-bug-example
Please note that the issue still happens even when all costume configs are disabled.