diff options
author | Peter Simons <simons@cryp.to> | 2010-10-20 20:07:31 +0200 |
---|---|---|
committer | Peter Simons <simons@cryp.to> | 2010-10-20 20:07:31 +0200 |
commit | 99d13f0429e3a3af2b46b617d776b9d46d6c5438 (patch) | |
tree | 8ccf8cedad4c7213ac26561fc6af7d97ab2e16ad /macro2m4.py | |
parent | 82ac11a5e40c32a7c7a30d2868d12e5b6c093d79 (diff) | |
download | autoconf-archive-99d13f0429e3a3af2b46b617d776b9d46d6c5438.tar.gz |
macro.py, macro2m4.py: minor fixes to make those scripts run with Python 3
Diffstat (limited to 'macro2m4.py')
-rwxr-xr-x | macro2m4.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/macro2m4.py b/macro2m4.py index c1709ba..bcd27d6 100755 --- a/macro2m4.py +++ b/macro2m4.py @@ -54,12 +54,12 @@ m = Macro(m4File) for i in range(len(m.description)): para = m.description[i] if para[0][0].isspace(): - spaces = min(map(countSpaces, para)) + spaces = min(list(map(countSpaces, para))) if spaces > 1: - m.description[i] = map(lambda l: ' ' + l[spaces:], para) + m.description[i] = [' ' + l[spaces:] for l in para] url = "http://www.gnu.org/software/autoconf-archive/%s.html" % m.name lineLen = max(len(url) + 2, 75) -m.url = "# %s\n# %s\n# %s" % ('=' * lineLen, (' ' * ((lineLen - len(url)) / 2)) + url, '=' * lineLen) +m.url = "# %s\n# %s\n# %s" % ('=' * lineLen, (' ' * int((lineLen - len(url)) / 2)) + url, '=' * lineLen) if m.__dict__.get("obsolete"): m.obsolete = "# OBSOLETE MACRO\n#\n" + '\n'.join(map(formatParagraph, m.obsolete)) + "\n#\n" else: |