Open lalib opened 11 months ago
Also saw a failure (although a slightly different one) with Spotless and Gradle here: https://github.com/openfga/java-sdk/actions/runs/6510767947/job/17685150920?pr=27
This issue should be refined: When did you encounter this issue? I tried the plugin on Java 21 in a JavaFX project (at https://github.com/koppor/jabref/pull/663) - and it worked.
This code fails to format with palantir-java-format 2.39.0:
final var currentOffsets = new HashMap<Integer, Long>();
currentOffsets.computeIfAbsent(partition, _ -> new AtomicLong()).set(consumerRecord.offset());
It generates
com.palantir.javaformat.java.FormatterException: 156:60: error: expected token: '_'; generated instead -> [Help 1]
For the interested readers: Using _
is from JEP-443. Good explanation at https://howtodoinjava.com/java/unnamed-patterns-and-variables/
What happened?
Failed with using Spotless Maven plugin and palantir rule: