On 7/21/16 3:25 AM, Alan Bateman wrote:
On 20/07/2016 22:47, Coleen Phillimore wrote:



Why aren't addmods and limitmods allowed be specified more than once on the command line and handled like the other ones?
It's last one wins, typical for most options when repeated. I could imagine someone composing a command line with --add-modules coming from multiple sources, they logically merge/union, so maybe there is a case for that. However --limit-modules is niche and I don't think makes sense to attempt to merge.

Well having subtle differences like this makes it difficult to explain to people, and nobody reads documentation in that much detail. It seems like you should try to be consistent, if it makes sense. But no, I don't know what limitmods does or whether you'd want to aggregate this.

Coleen


We should add an option -XX:+UseUnsafe to be a shortcut for this:

--add-exports=java.base/jdk.internal.misc=ALL-UNNAMED
That may be useful for JDK tests but it makes it too easy to get to jdk.internal.misc.Unsafe. For usages outside of the JDK then I think they should continue to use sun.misc.Unsafe (JEP 260 etc.) and gradually reduce that over time as better approaches are available in the platform.

-Alan

Reply via email to