develooper Front page | perl.perl5.porters | Postings from December 2001

[PATCH} typo fix in Carp/Heavy.pm

Thread Next
From:
Robert Spier
Date:
December 20, 2001 08:11
Subject:
[PATCH} typo fix in Carp/Heavy.pm
Message ID:
15394.3416.693353.107334@rls.cx

lib/Carp.pm defines $MaxArgLen, but Carp/Heavy.pm used $MaxLenArg.

Patch against perl-snap updates Carp/Heavy.pm to use $MaxArgLen for
consistency and so it'll work as expected.  (For people who only look
at Carp.pm especially.)

-R


--- lib/Carp/Heavy.pm.orig      Thu Dec 20 08:04:36 2001
+++ lib/Carp/Heavy.pm   Thu Dec 20 08:06:20 2001
@@ -12,7 +12,7 @@
 # On one line so MakeMaker will see it.
 use Carp;  our $VERSION = $Carp::VERSION;
 
-our ($CarpLevel, $MaxArgNums, $MaxEvalLen, $MaxLenArg, $Verbose);
+our ($CarpLevel, $MaxArgNums, $MaxEvalLen, $MaxArgLen, $Verbose);
 
 sub caller_info {
   my $i = shift(@_) + 1;
@@ -50,7 +50,7 @@
       $arg = defined($overload::VERSION) ? overload::StrVal($arg) :
       "$arg";
   }
   $arg =~ s/'/\\'/g;
-  $arg = str_len_trim($arg, $MaxLenArg);
+  $arg = str_len_trim($arg, $MaxArgLen);
   
   # Quote it?
   $arg = "'$arg'" unless $arg =~ /^-?[\d.]+\z/;


-- 


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About