about summary refs log tree commit diff
path: root/src/etc
diff options
context:
space:
mode:
authorBoris Egorov <jightuse@gmail.com>2014-04-07 19:01:10 +0700
committerAlex Crichton <alex@alexcrichton.com>2014-04-08 00:03:12 -0700
commit00cbda2d0af81a054ba61bd237f98e033ba7a2fa (patch)
tree521bae1c4c0dfea6e9691f58c7caec270c0afea5 /src/etc
parentde2567dec9cfceec59db5d6d17df09c05f70d5a1 (diff)
downloadrust-00cbda2d0af81a054ba61bd237f98e033ba7a2fa.tar.gz
rust-00cbda2d0af81a054ba61bd237f98e033ba7a2fa.zip
Improve searching for XXX in tidy script (#3303)
Few places where previous version of tidy script cannot find XXX:
* inside one-line comment preceding by a few spaces;
* inside multiline comments (now it finds it if multiline comment starts
on the same line with XXX).

Change occurences of XXX found by new tidy script.
Diffstat (limited to 'src/etc')
-rw-r--r--src/etc/tidy.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/etc/tidy.py b/src/etc/tidy.py
index 6529b4d084e..3d44c27a16e 100644
--- a/src/etc/tidy.py
+++ b/src/etc/tidy.py
@@ -65,10 +65,11 @@ try:
                 check_tab = False
             if line.find(linelength_flag) != -1:
                 check_linelength = False
-            if line.find("// XXX") != -1:
-                report_err("XXX is no longer necessary, use FIXME")
             if line.find("TODO") != -1:
                 report_err("TODO is deprecated; use FIXME")
+            match = re.match(r'^.*/(\*|/!?)\s*XXX', line)
+            if match:
+                report_err("XXX is no longer necessary, use FIXME")
             match = re.match(r'^.*//\s*(NOTE.*)$', line)
             if match:
                 m = match.group(1)