[Bps-public-commit] r17443 - in Path-Dispatcher/trunk: lib/Path/Dispatcher lib/Path/Dispatcher/Rule

sartak at bestpractical.com sartak at bestpractical.com
Tue Dec 30 14:21:08 EST 2008


Author: sartak
Date: Tue Dec 30 14:21:07 2008
New Revision: 17443

Modified:
   Path-Dispatcher/trunk/   (props changed)
   Path-Dispatcher/trunk/lib/Path/Dispatcher/Match.pm
   Path-Dispatcher/trunk/lib/Path/Dispatcher/Rule/Always.pm

Log:
 r78061 at onn:  sartak | 2008-12-29 23:54:27 -0500
 More cleanup


Modified: Path-Dispatcher/trunk/lib/Path/Dispatcher/Match.pm
==============================================================================
--- Path-Dispatcher/trunk/lib/Path/Dispatcher/Match.pm	(original)
+++ Path-Dispatcher/trunk/lib/Path/Dispatcher/Match.pm	Tue Dec 30 14:21:07 2008
@@ -63,14 +63,15 @@
     # we don't have direct write access to $1 and friends, so we have to
     # do this little hack. the only way we can update $1 is by matching
     # against a regex (5.10 fixes that)..
-    my $re = join '', map { "(\Q$_\E)" } @_;
-    my $str = join '', @_;
+    my $re  = join '', map { "(\Q$_\E)" } @_;
+    my $str = join '',                    @_;
 
     # we need to check length because Perl's annoying gotcha of the empty regex
     # actually being an alias for whatever the previously used regex was 
     # (useful last decade when qr// hadn't been invented)
     # we need to do the match anyway, because we have to clear the number vars
     ($str, $re) = ("x", "x") if length($str) == 0;
+
     $str =~ $re
         or die "Unable to match '$str' against a copy of itself ($re)!";
 

Modified: Path-Dispatcher/trunk/lib/Path/Dispatcher/Rule/Always.pm
==============================================================================
--- Path-Dispatcher/trunk/lib/Path/Dispatcher/Rule/Always.pm	(original)
+++ Path-Dispatcher/trunk/lib/Path/Dispatcher/Rule/Always.pm	Tue Dec 30 14:21:07 2008
@@ -26,4 +26,3 @@
 
 =cut
 
-



More information about the Bps-public-commit mailing list