fix a coiple of SyntaxWarning on python 3.8

This commit is contained in:
Cosimo Lupo 2020-01-30 10:47:57 +00:00
parent 8c1654397d
commit 39b02fd224
No known key found for this signature in database
GPG Key ID: 20D4A261E4A0E642
2 changed files with 2 additions and 2 deletions

View File

@ -705,7 +705,7 @@ class Parser(object):
else:
keyword = None
self.expect_symbol_(";")
if len(new) is 0 and not any(lookups):
if len(new) == 0 and not any(lookups):
raise FeatureLibError(
'Expected "by", "from" or explicit lookup references',
self.cur_token_location_)

View File

@ -854,7 +854,7 @@ def parseLookup(lines, tableTag, font, lookupMap=None):
lookup.SubTable = subtables
lookup.SubTableCount = len(lookup.SubTable)
if lookup.SubTableCount is 0:
if lookup.SubTableCount == 0:
# Remove this return when following is fixed:
# https://github.com/fonttools/fonttools/issues/789
return None