summaryrefslogtreecommitdiffstats
path: root/bin/linecount.py
diff options
context:
space:
mode:
authorGreg Noel <GregNoel@tigris.org>2010-03-25 04:14:28 (GMT)
committerGreg Noel <GregNoel@tigris.org>2010-03-25 04:14:28 (GMT)
commit22d352500f1cd6bd0c53d788a5dc44a1fefa676e (patch)
tree0984fd581082c27cfbfbb7f94d5751b0e6fd2741 /bin/linecount.py
parent75ac32ac8e32076e25b72a19eb56340cc585fa4e (diff)
downloadSCons-22d352500f1cd6bd0c53d788a5dc44a1fefa676e.zip
SCons-22d352500f1cd6bd0c53d788a5dc44a1fefa676e.tar.gz
SCons-22d352500f1cd6bd0c53d788a5dc44a1fefa676e.tar.bz2
Move 2.0 changes collected in branches/pending back to trunk for further
development. Note that this set of changes is NOT backward-compatible; the trunk no longer works with Python 1.5.2, 2.0, or 2.1.
Diffstat (limited to 'bin/linecount.py')
-rw-r--r--bin/linecount.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/linecount.py b/bin/linecount.py
index 33f9f73..715d207 100644
--- a/bin/linecount.py
+++ b/bin/linecount.py
@@ -22,11 +22,11 @@
# non-comment lines. The last figure (non-comment) lines is the most
# interesting one for most purposes.
#
+from __future__ import generators ### KEEP FOR COMPATIBILITY FIXERS
__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
import os.path
-import string
fmt = "%-16s %5s %7s %9s %11s %11s"
@@ -85,8 +85,8 @@ sources = Collection('sources', pred=is_source)
def t(arg, dirname, names):
try: names.remove('.svn')
except ValueError: pass
- names = filter(arg, names)
- arg.extend(map(lambda n, d=dirname: os.path.join(d, n), names))
+ names = list(filter(arg, names))
+ arg.extend([os.path.join(dirname, n) for n in names])
os.path.walk('src', t, src_Tests_py_tests)
os.path.walk('src', t, src_test_tests)