[cp-patches] RFC: @file support for gjavah & gjar

Tom Tromey tromey at redhat.com
Wed Jun 4 15:08:09 UTC 2008


>>>>> "Robert" == Robert Schuster <theBohemian at gmx.net> writes:

Robert> The other tools are not affected by this change nor does this modify the
Robert> core getopt functionality (except that I made the 'programName' field
Robert> protected - was private).

I don't think we need this to be protected.  Instead I think
parseFileList and notifyFile can throw an OptionException.  Parser
will emit the proper error message in this case.

At least, I think that should work, since that was the idea behind the
OptionException design -- clients can throw an exception and only the
parser framework needs to know how to format an error message.  If
that does not work perhaps we can add a new method to Parser -- I'd
rather avoid exposing a field.

Some of the indentation seems wrong to me, though I always find it a
bit hard to tell due to diffs making tabs look weird.

Aside from those things this looks good to me.

Robert> +		// While not reached end of line ...
Robert> +    while (start < length)

E.g., this comment seems indented improperly.

Robert> +  	public void notifyFile(String fileArgument)
Robert> +		throws OptionException

In context this looks like it should be further to the right.

Robert> +  	{
Robert> +			if (fileArgument.codePointAt(0) == '@')
Robert> +			{

Likewise this brace.
 
Tom



More information about the Classpath-patches mailing list