contrib/check-code.py
changeset 19793 6fb1b7728719
parent 19745 22a70f31e3e9
child 19872 681f7b9213a4
--- a/contrib/check-code.py	Fri Sep 20 10:16:55 2013 -0400
+++ b/contrib/check-code.py	Fri Sep 20 10:18:09 2013 -0400
@@ -162,6 +162,9 @@
      "tuple parameter unpacking not available in Python 3+"),
     (r'lambda\s*\(.*,.*\)',
      "tuple parameter unpacking not available in Python 3+"),
+    (r'import (.+,[^.]+\.[^.]+|[^.]+\.[^.]+,)',
+     '2to3 can\'t always rewrite "import qux, foo.bar", '
+     'use "import foo.bar" on its own line instead.'),
     (r'(?<!def)\s+(cmp)\(', "cmp is not available in Python 3+"),
     (r'\breduce\s*\(.*', "reduce is not available in Python 3+"),
     (r'\.has_key\b', "dict.has_key is not available in Python 3+"),