On 31/05/2016 10:11, Gunnar Morling wrote:
Hi Alan,
I could narrow down the trigger for this issue: It's related to
referring a non-existing module in module-info.java.
Normally, that error is detected by javac which emits a correct
compilation error:
src/main/java/module-info.java:4: error: module not found: xyz
But when specifying the -processorpath option, this check seems to be
bypassed somehow. The code in Modules#checkCyclicDependencies() then
fails with an NPE as the "directive" of the JCRequires is null (see [1]).
That's the module-info.java:
module foo {
requires nonexistent;
}
And that's the javac invocation:
javac -processorpath someprocessor.jar -d mods/npe-test $(find
src/main/java -name "*.java")
Please let me know if you need any further information.
Thanks, I've created JDK-8158224 [1] to track this.
-Alan
[1] https://bugs.openjdk.java.net/browse/JDK-8158224