On Wed, Jun 15, 2005 at 12:38:21PM -0400, Mike T. Machenry wrote:
> sub process { ... }
> GetOptions ('<>' => \&process);
>
> produces the following error:
>
> Error in option spec: "CODE(0x80e4bbc)"
>
> Does anyone know how I can pull out the non-option arguments without needing
> to have some named option present.
It works for me:
#!/usr/local/bin/perl -w
use strict;
use Getopt::Long;
sub process { print "@_\n" }
GetOptions ('<>' => \&process);
__END__
% perl opts.pl foo
foo
%
Getopt::Long version 2.34
Ronald
_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm