Draft JEP: Launch Single-File Source-Code Programs

Andrew Haley aph at redhat.com
Tue Feb 13 18:42:23 UTC 2018

On 13/02/18 17:56, Jonathan Gibbons wrote:
> On 2/13/18 6:48 AM, Andrew Haley wrote:
>> On 13/02/18 13:24, David Lloyd wrote:
>>> I think the shell takes care of that bit...
>> It does, but we do need to say what gets passed.  jvm arguments,
>> in particular, would be very useful.
> The problem here is that it seems that shells are inconsistent with how 
> they handle arguments on the first line. This is specifically called out 
> as a portability problem in [1].
> That makes it difficult for the main Java launcher to handle these 
> arguments. It would be wrong to make a general change to the Java 
> launcher to reparse arguments containing spaces as individual options.

OK, I see what you mean.  I had thought that Python did this properly,
but I just tried it and it doesn't work.  Well, it works kinda-sorta
but exactly one argument can be passed on the command line.  Eww.  :-)

Andrew Haley
Java Platform Lead Engineer
Red Hat UK Ltd. <https://www.redhat.com>
EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671

More information about the jdk-dev mailing list