tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Felix Schumacher <felix.schumac...@internetallee.de>
Subject Re: svn commit: r1099032 - in /tomcat/trunk/res/scripts: ./ check-mime.pl
Date Sun, 08 May 2011 12:38:59 GMT
Hi Rainer,

Am Sonntag, den 08.05.2011, 14:20 +0200 schrieb Rainer Jung:
> Hi Felix,
> 
> TMTOWTDI. For standalone scripts I don't care very much about style. 
right :)
> Let's see below ...
> 
> On 08.05.2011 13:17, Felix Schumacher wrote:
> > Hi Rainer,
> >
> >> +
> >> +# Parse arguments:
> >> +# -m: mime.types file (httpd) to use
> >> +# -i: input web.xml file to check
> >> +# -o: output web.xml file (gets generated and overwritten)
> >> +
> >> +$Getopt::Std::STANDARD_HELP_VERSION = 1;
> >> +our($opt_m, $opt_i, $opt_o);
> > Why should those options be visible by everyone outside this package?
> > 'my' should be enough:
> > my ($opt_m, $opt_i, $opt_o);
> 
> Doesn't work. Seems getopts needs "our".
I tried it and I thougt it works, but you are right. In my tests it eats
$opt_m if used with my, the other parameters are set though :( I usually
use getopt with a hash reference...

But enough of those bagatelles.

Regards
 Felix



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message