2to3 --fix=filter

This commit is contained in:
Behdad Esfahbod 2013-11-27 04:07:28 -05:00
parent 7cc6d271ac
commit 28aeabb08b
2 changed files with 3 additions and 3 deletions

View File

@ -412,7 +412,7 @@ class EblcIndexSubTable:
(name, (startByte, endByte)) = args
return startByte < endByte
# Remove all skip glyphs.
dataPairs = filter(isValidLocation, zip(self.names, self.locations))
dataPairs = list(filter(isValidLocation, zip(self.names, self.locations)))
self.names, self.locations = map(list, zip(*dataPairs))
# A closure for creating a custom mixin. This is done because formats 1 and 3

View File

@ -1220,7 +1220,7 @@ class cmap_format_14(CmapSubtable):
for uvs in uvsList:
entryList = uvsDict[uvs]
defList = filter(lambda entry: entry[1] == None, entryList)
defList = [entry for entry in entryList if entry[1] == None]
if defList:
defList = map(lambda entry: entry[0], defList)
defOVSOffset = offset
@ -1247,7 +1247,7 @@ class cmap_format_14(CmapSubtable):
else:
defOVSOffset = 0
ndefList = filter(lambda entry: entry[1] != None, entryList)
ndefList = [entry for entry in entryList if entry[1] != None]
if ndefList:
nonDefUVSOffset = offset
ndefList.sort()