Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
and the resultant (when I try to run the program)foreach my $arg (@ARGV) { if( $arg =~ /^-B(\d+)$/ ) { # months Before $before = $1; } elsif( $arg =~ /^-B$/ ) { $before = shift( @ARGV ); if( $before !~ /^\d+/ ) { die "Bad before argument ($before)\n"; }
This were good in 5.34. I tried looking in the release notes for changes and (well - - - I'm no programmer - - - sorry) I can't spot anything that would be relevant to my issue. TIA/$ /usr/local/bin/cal2.pl -B 4 Uncaught exception from user code: Bad before argument (-B)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: hmm - - - something has changed in perl (from 5.34 to 5.36
by choroba (Cardinal) on Nov 23, 2022 at 17:35 UTC | |
by Tux (Canon) on Nov 24, 2022 at 10:12 UTC | |
|
Re: hmm - - - something has changed in perl (from 5.34 to 5.36
by Corion (Patriarch) on Nov 23, 2022 at 17:39 UTC | |
|
Re: hmm - - - something has changed in perl (from 5.34 to 5.36
by tybalt89 (Monsignor) on Nov 23, 2022 at 18:34 UTC | |
|
Re: hmm - - - something has changed in perl (from 5.34 to 5.36
by o1bigtenor (Initiate) on Nov 23, 2022 at 20:57 UTC | |
by karlgoethebier (Abbot) on Nov 24, 2022 at 14:46 UTC |