amelentev / java-oo

Java Operator Overloading
http://amelentev.github.io/java-oo/
268 stars 31 forks source link

IllegalAccessError when compiling with Maven running on Java 16 #69

Closed Gaming32 closed 3 years ago

Gaming32 commented 3 years ago

When attempting to compile a project on which maven is running Java 16, the error message java.lang.IllegalAccessError: class javaoo.javac8.OOProcessor (in unnamed module @0x3a175162) cannot access class com.sun.tools.javac.processing.JavacProcessingEnvironment (in module jdk.compiler) because module jdk.compiler does not export com.sun.tools.javac.processing to unnamed module @0x3a175162 appears. This happens regardless of the properties of the Maven compiler plugin, as setting the "source" and "target" tags to 1.8 has no effect. However, changing JAVA_HOME to use JDK 1.8 instead of using JDK 16 results in a successful compilation.

amelentev commented 3 years ago

The plugin only works on JDK7 and 8. For higher versions see #59