@@ -346,7 +346,7 @@ def __init__(self, term: BoundTerm[L]):
346346
347347 def __eq__ (self , other : Any ) -> bool :
348348 """Return the equality of two instances of the BoundPredicate class."""
349- if isinstance (other , BoundPredicate ):
349+ if isinstance (other , self . __class__ ):
350350 return self .term == other .term
351351 return False
352352
@@ -567,7 +567,7 @@ def __repr__(self) -> str:
567567
568568 def __eq__ (self , other : Any ) -> bool :
569569 """Return the equality of two instances of the BoundSetPredicate class."""
570- return self .term == other .term and self .literals == other .literals if isinstance (other , BoundSetPredicate ) else False
570+ return self .term == other .term and self .literals == other .literals if isinstance (other , self . __class__ ) else False
571571
572572 def __getnewargs__ (self ) -> Tuple [BoundTerm [L ], Set [Literal [L ]]]:
573573 """Pickle the BoundSetPredicate class."""
@@ -595,7 +595,7 @@ def __invert__(self) -> BoundNotIn[L]:
595595
596596 def __eq__ (self , other : Any ) -> bool :
597597 """Return the equality of two instances of the BoundIn class."""
598- return self .term == other .term and self .literals == other .literals if isinstance (other , BoundIn ) else False
598+ return self .term == other .term and self .literals == other .literals if isinstance (other , self . __class__ ) else False
599599
600600 @property
601601 def as_unbound (self ) -> Type [In [L ]]:
@@ -725,7 +725,7 @@ def __init__(self, term: BoundTerm[L], literal: Literal[L]): # pylint: disable=
725725
726726 def __eq__ (self , other : Any ) -> bool :
727727 """Return the equality of two instances of the BoundLiteralPredicate class."""
728- if isinstance (other , BoundLiteralPredicate ):
728+ if isinstance (other , self . __class__ ):
729729 return self .term == other .term and self .literal == other .literal
730730 return False
731731
0 commit comments