#1513299: cleanup some map() uses where a comprehension works better.

This commit is contained in:
Georg Brandl 2010-12-04 10:39:14 +00:00
parent 8334fd9285
commit cbd2ab1311
6 changed files with 7 additions and 7 deletions

View file

@ -276,7 +276,7 @@ class LongTest(unittest.TestCase):
digits = digits or [0]
return '-'[:sign] + \
{2: '0b', 8: '0o', 10: '', 16: '0x'}[base] + \
"".join(map(lambda i: "0123456789abcdef"[i], digits))
"".join("0123456789abcdef"[i] for i in digits)
def check_format_1(self, x):
for base, mapper in (8, oct), (10, repr), (16, hex):