[Bps-public-commit] r15038 - in Carp-REPL: .

sartak at bestpractical.com sartak at bestpractical.com
Tue Aug 12 06:59:36 EDT 2008


Author: sartak
Date: Tue Aug 12 06:59:34 2008
New Revision: 15038

Modified:
   Carp-REPL/   (props changed)
   Carp-REPL/lib/Devel/REPL/Plugin/Carp/REPL.pm

Log:
 r69341 at onn:  sartak | 2008-08-12 06:58:23 -0400
 One last commit for 0.13, this finally fixes the line-ending problem in :l


Modified: Carp-REPL/lib/Devel/REPL/Plugin/Carp/REPL.pm
==============================================================================
--- Carp-REPL/lib/Devel/REPL/Plugin/Carp/REPL.pm	(original)
+++ Carp-REPL/lib/Devel/REPL/Plugin/Carp/REPL.pm	Tue Aug 12 06:59:34 2008
@@ -113,17 +113,20 @@
         $min = 0 if $min < 0;
         $max = $#code if $max > $#code;
 
+        my @lines;
         $self->print("File $file:\n");
         for my $cur ($min .. $max) {
             next if !defined($code[$cur]);
 
-            $self->print(sprintf "%s%*d: %s",
+            push @lines, sprintf "%s%*d: %s",
                             $cur + 1 == $num ? '*' : ' ',
                             length($max),
                             $cur + 1,
-                            $code[$cur]);
+                            $code[$cur];
         }
 
+        $self->print(join "\n", @lines);
+
         return '';
     }
 



More information about the Bps-public-commit mailing list