]> gitweb.factorcode.org Git - factor.git/blobdiff - extra/lint/vocabs/vocabs.factor
Fixed Regexp to Handle \" Properly
[factor.git] / extra / lint / vocabs / vocabs.factor
index 358a353dd9bf9f57cbd091a83fca230dba7a2a44..c701a05145b70ec9b3db9029dd6628d4f1898f39 100644 (file)
@@ -34,8 +34,8 @@ SYMBOL: old-dictionary
 : find-import-statements ( string -- seq )
     "USING: [^;]+ ;|USE: \\S+" <regexp> all-matching-subseqs ;
 
-: clean-up-source ( string -- string )
-    "\"(\\\"|[^\"]*|\n)\"|(R/ (\\\\/|[^/])*/)|\\\\\\s+(USE:|USING:)|POSTPONE:\\s+(USE:|USING:)|! ([^\n])*" <regexp> "" re-replace ;
+: clean-up-source ( string -- string ) 
+    "\"(\\\\\"|[^\"])*\"|(R/ (\\\\/|[^/])*/)|\\\\\\s+(USE:|USING:)|POSTPONE:\\s+(USE:|USING:)|! [^\n]*" <regexp> "" re-replace ;
 
 : strip-syntax ( seq -- seq )
     [ "USING: | ;|USE: " <regexp> " " re-replace ] map ;