Re: Parameter parsing with Getopt::Long in functions

2002-06-15 Thread Robert Kasunic
Hello Paul, On Sat, Jun 15, 2002 at 06:27:18PM +0200, Paul Johnson wrote: > > sub test_params() > > { > >@ARGV=@_; > local @ARGV = split " ", shift; > Hopefully you can work out what the problem was and why the fix works. I can't believe how blind I've been. Thank you very much. I now c

Re: Parameter parsing with Getopt::Long in functions

2002-06-15 Thread drieux
On Saturday, June 15, 2002, at 09:27 , Paul Johnson wrote: > On Sat, Jun 15, 2002 at 06:10:23PM +0200, Robert Kasunic wrote: >> Hello, [..] >> sub test_params() >> { >>@ARGV=@_; > > local @ARGV = split " ", shift; > >>print "ARGV: @ARGV\n"; >> } >> >> &test_params("-a argument_

Re: Parameter parsing with Getopt::Long in functions

2002-06-15 Thread drieux
On Saturday, June 15, 2002, at 09:10 , Robert Kasunic wrote: > > I'm trying to use Getopt::Long for parsing parameters passed to a > function. I tried to test if that works by using the following script. > > --- > #!/usr/bin/perl -w > use stric

Re: Parameter parsing with Getopt::Long in functions

2002-06-15 Thread Paul Johnson
On Sat, Jun 15, 2002 at 06:10:23PM +0200, Robert Kasunic wrote: > Hello, > > I'm trying to use Getopt::Long for parsing parameters passed to a > function. I tried to test if that works by using the following script. > > --- > #!/usr/bin/perl -w

Parameter parsing with Getopt::Long in functions

2002-06-15 Thread Robert Kasunic
Hello, I'm trying to use Getopt::Long for parsing parameters passed to a function. I tried to test if that works by using the following script. --- #!/usr/bin/perl -w use strict; use Getopt::Long; sub test_params() { @ARGV=@_; print "ARG