py3: fixes for docx input

This commit is contained in:
Kovid Goyal 2019-04-18 08:55:20 +05:30
parent 7e303f6503
commit c1333ea71b
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -11,8 +11,29 @@ from collections import OrderedDict
from polyglot.builtins import iteritems
class Inherit:
pass
class Inherit(object):
def __eq__(self, other):
return other is self
def __hash__(self):
return id(self)
def __lt__(self, other):
return False
def __gt__(self, other):
return other is not self
def __ge__(self, other):
if self is other:
return True
return True
def __le__(self, other):
if self is other:
return True
return False
inherit = Inherit()