[Bps-public-commit] CSS-Squish branch, master, updated. v0.09-7-g0c973be

Ruslan Zakirov ruz at bestpractical.com
Thu Sep 8 10:33:13 EDT 2011


The branch, master has been updated
       via  0c973be8bd2daf3a1bd45e21bf9e66f9f158633c (commit)
      from  e2a3aa30ca231a0c32c3ef5907756f17ff3fc68f (commit)

Summary of changes:
 lib/CSS/Squish.pm |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

- Log -----------------------------------------------------------------
commit 0c973be8bd2daf3a1bd45e21bf9e66f9f158633c
Author: Ruslan Zakirov <ruz at bestpractical.com>
Date:   Thu Sep 8 18:32:58 2011 +0400

    use redo instead of goto

diff --git a/lib/CSS/Squish.pm b/lib/CSS/Squish.pm
index d7c6a0c..1ba28a7 100644
--- a/lib/CSS/Squish.pm
+++ b/lib/CSS/Squish.pm
@@ -155,8 +155,7 @@ sub _concatenate_to {
     my $file = shift;
     my $seen = shift || {};
 
-    while ( my $line = <$fh> ) {
-        REDO:
+    LINE: while ( my $line = <$fh> ) {
         # skip empty lines and one line comments
         if ( $line =~ /^\s*(?:$COMMENT\s*)*$/o ) {
             print $dest $line;
@@ -166,7 +165,7 @@ sub _concatenate_to {
                 $line .= $tmp;
                 next unless $line =~ s/^(\s*$COMMENT)//o;
 
-                print $dest $1; goto REDO;
+                print $dest $1; redo LINE;
             }
             # endless comment
             print $dest $line; last;

-----------------------------------------------------------------------



More information about the Bps-public-commit mailing list