On Mon, 2008-04-07 at 16:49 +0200, Papp Gyozo (VBuster) wrote:

> Again ... forgot to say that the most annoying situation when the very 
> same option is given in both command line and config file. Reporting an 
> error in such cases looks a little bit weird for me. 

Same here, which is why I like the idea of the temporary struct for
argv[], even though we really only need the config file option from it
initially. Its useful to hold this struct for issuing warnings.

If tmp->option and final->option are present and not the same, a warning
could be issued saying "Warning, command line option (option) takes
precedence over configuration directive (option)"

In most cases the user would know that, since command line options are
supposed to override configuration directives .. but its still handy and
(imho) more 'proper' to be noisy about it.

I'd actually be all for a toggle that stops freeing of the temporary
structure so that its up to us to free it once we're done with it.

So, really, the temporary structure would serve two useful purposes.

Cheers,
--Tim

-- 
Monkey + Typewriter = Echoreply ( http://echoreply.us )



_______________________________________________
Help-gengetopt mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-gengetopt

Reply via email to