summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Andres Klode <jak@debian.org>2009-06-03 17:45:06 +0200
committerJulian Andres Klode <jak@debian.org>2009-06-03 17:45:06 +0200
commitd51b51bbc2c7e5d5109f0aa920d730fa6e75b6fb (patch)
tree4c54000f12b8a5f7def945120eef1c0e1d706b16
parent7051066cf258caa2a3fd45271faa3d46b8a6d98a (diff)
downloadpython-apt-d51b51bbc2c7e5d5109f0aa920d730fa6e75b6fb.tar.gz
utils/migrate-0.8.py: Fix function detection.
-rwxr-xr-xutils/migrate-0.8.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/utils/migrate-0.8.py b/utils/migrate-0.8.py
index 99adf652..61d3865a 100755
--- a/utils/migrate-0.8.py
+++ b/utils/migrate-0.8.py
@@ -90,6 +90,8 @@ def find_deprecated_cpp():
name = line.split(",")[0].strip().strip('{"')
if not 'module' in fname:
name = '.' + name
+ else:
+ all_old.add('.' + name)
all_old.add(name)
line = lines.pop(0)
return all_old
@@ -186,7 +188,12 @@ if color:
'simply highlight the matched words (like grep).', 79)
print
-all_old = find_deprecated_cpp() | find_deprecated_py()
+all_old = find_deprecated_cpp()
+
+if not '-P' in sys.argv:
+ all_old |= find_deprecated_py()
+else:
+ sys.argv.remove('-P')
files = set()
for path in sys.argv[1:]: