Author: adam-guest
Date: 2008-03-18 07:33:11 +0000 (Tue, 18 Mar 2008)
New Revision: 1168

Modified:
   trunk/scripts/checkbashisms.pl
Log:
Remove "quoted quotes" before removing single quoted strings

Modified: trunk/scripts/checkbashisms.pl
===================================================================
--- trunk/scripts/checkbashisms.pl      2008-03-18 00:49:37 UTC (rev 1167)
+++ trunk/scripts/checkbashisms.pl      2008-03-18 07:33:11 UTC (rev 1168)
@@ -288,6 +288,13 @@
            }
 
            unless ($found) {
+               # Remove "quoted quotes". They're likely to be inside
+               # another pair of quotes; we're not interested in
+               # them for their own sake and removing them makes finding
+               # the limits of the outer pair far easier.
+               $line =~ s/(^|[^\\\'\"])\"\'\"/$1/g;
+               $line =~ s/(^|[^\\\'\"])\'\"\'/$1/g;
+
                # Ignore anything inside single quotes; it could be an
                # argument to grep or the like.
                $line =~ s/(^|[^\\](?:\\\\)*)\'(?:\\.|[^\\\'])+\'/$1''/g;



-- 
To unsubscribe, send mail to [EMAIL PROTECTED]

Reply via email to