qulice
qulice copied to clipboard
Java 17 record type not supported
I'm using qulice
on a Java 17 project
I have this record
public record ParseError(
Recognizer<?, ?> recognizer,
Object offendingSymbol,
int line,
int charPositionInLine,
String msg
) {
}
when running the build I get
ParseError.java:17:8: unexpected token: record
@elbraulio definitely a bug. Let us try to fix. Or maybe you can help with a pull request?)
@yegor256 this is my try:
this dependency in qulice-checkstyle
https://github.com/yegor256/qulice/blob/c2d778d9402efaf24d07d8fbbffd491edc2bed28/qulice-checkstyle/pom.xml#L69-L83
is the one that logs the error unexpected token: record
at this line
https://github.com/yegor256/qulice/blob/277d04dafb35aeb36accb4e620d19a744ad173d0/qulice-checkstyle/src/main/java/com/qulice/checkstyle/CheckstyleValidator.java#L108
the ticket https://github.com/checkstyle/checkstyle/issues/9085 suggests to use the version 8.38 to get it fixed.
from the release notes, java 14 was supported from 8.36 https://checkstyle.org/releasenotes.html#Release_8.36
The problem is that the dependency can't be updated up to 8.38 because of some methods that qulice uses were removed after 8.15 instead of being deprecated. Therefore, it is not backwards compatible :(
@Graur maybe you can help here?