javac options interspersed with sourcefiles: supported?
Anthony Vanelverdinghe
anthony.vanelverdinghe at gmail.com
Fri May 19 18:12:09 UTC 2017
Hi
Though the documentation [1] has a synopsis of `javac [options]
[sourcefiles]`, javac actually allows options and sourcefiles to be
interspersed, e.g.:
javac -J--add-modules=java.xml.ws.annotation Foo.java -g Bar.java
--release 9 -sourcepath Baz.java --release 8 -cp '*'
I find this confusing (especially with long commands like the ones Maven
produces) & would expect it to be rejected, so I'm wondering: is this
supported behavior? If so, I believe the documentation should be updated
accordingly. If not, I believe javac should explicitly reject such commands.
[1] http://docs.oracle.com/javase/9/tools/javac.htm
Kind regards,
Anthony
More information about the compiler-dev
mailing list