]> granicus.if.org Git - python/commitdiff
use the long names for re compilation options; this makes it easier to
authorFred Drake <fdrake@acm.org>
Tue, 2 Sep 2003 16:01:07 +0000 (16:01 +0000)
committerFred Drake <fdrake@acm.org>
Tue, 2 Sep 2003 16:01:07 +0000 (16:01 +0000)
figure out what the code is doing

Lib/csv.py

index 37b9e16c31aa683d0e089e3053c7242934ce5285..fcb8a8fedcea790cb4c1759d80142a691d8fedfc 100644 (file)
@@ -207,7 +207,7 @@ class Sniffer:
                       '(?:^|\n)(?P<quote>["\']).*?(?P=quote)(?P<delim>[^\w\n"\'])(?P<space> ?)',   #  ".*?",
                       '(?P<delim>>[^\w\n"\'])(?P<space> ?)(?P<quote>["\']).*?(?P=quote)(?:$|\n)',  # ,".*?"
                       '(?:^|\n)(?P<quote>["\']).*?(?P=quote)(?:$|\n)'):                            #  ".*?" (no delim, no space)
-            regexp = re.compile(restr, re.S | re.M)
+            regexp = re.compile(restr, re.DOTALL | re.MULTILINE)
             matches = regexp.findall(data)
             if matches:
                 break