Re: [PATCH] Fix sloppy Getopt::Long.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, May 06, 2009 at 10:24:50AM -0700, Junio C Hamano wrote:
> >> +			{ '' => \$_stdin, 'stdin' => \$_stdin,
> >> +			  %cmt_opts, %fc_opts, } ],
> > I confirm that it does correctly set the $_stdin variable (tested
> > briefly).
> Wait a minute.  Do you mean we would also need the above "explicit empty
> argument sets $_stdin"?  Wasn't it your earlier analysis/claim that the
> caller already takes care of a lone "-"?
I'd originally considered a single '-' as an argument not an option,
meaning stdin, not being processed within the getopt framework, but
instead being handled later.

> Or do you mean "yes it would also work but it is not necessary"?
Using Eric's change makes it explicit what is expected: Passing
'--stdin' is the same as passing '-'.

-- 
Robin Hugh Johnson
Gentoo Linux Developer & Infra Guy
E-Mail     : robbat2@xxxxxxxxxx
GnuPG FP   : 11AC BA4F 4778 E3F6 E4ED  F38E B27B 944E 3488 4E85

Attachment: pgpmsmWNy49Jg.pgp
Description: PGP signature


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]