In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] (Christian Stalp) writes:
>What can I do to use getopt() and use strict?
>If I use strict I have to declare all of my variables. And if I do this, perl
>ignores my getopt(s) single-chars. Is this normal? What can I do to solve
>this?
Learn about references; there is another argument allowed for the
getopts() function. Try this:
use Getopt::Std;
my %opt;
getopts('abcde', \%opt);
Now run that with some options and inspect the hash %opt after the
getopts() call.
>I want to use perl with "-w" option and the "strict" pracma. Is this posible?
Not only possible, I consider it mandatory :-)
--
Peter Scott
http://www.perldebugged.com/
*** NEW *** http://www.perlmedic.com/
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>