This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Patch: FYI: support -? and -X


>>>>> "Ranjit" == Ranjit Mathew <rmathew@hotmail.com> writes:

>> +	      printf ("gij: currently no -X options are recognized\n");

Ranjit> printf ("%s: currently no -X options are recognized\n", argv[0]);

Ranjit> Or not?

I was following the convention already in the code.
I'm not certain this is best.

It's usually pretty ugly when the program prints:

    /foo/bar/install/bin/gij: blah blah blah

OTOH, it is confusing if you have a symlink named "java" or something
and it prints "gij".  I think some people compromise by stripping off
the directory components from argv[0].

The standards seem pretty silent on this.  AFAICT they only talk
about the specific case of what to print for --version.

>> +	      exit (0);
Ranjit> exit (1);
Ranjit> Since this is an error and the execution did not succeed.

`gij -X' is a request to print the supported -X options.  So, it did
succeed.

BTW I consider this patch a bit of a hack.  We probably could
meaningfully support some -X options; at least -Xmx and -Xms, and
maybe some GC debugging options.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]