Add __repr__ to SerializedProgram`.

This commit is contained in:
Richard Kiss
2021-02-22 12:26:53 -08:00
parent c8fe842bbc
commit bbd820cb91
+3
View File
@@ -152,6 +152,9 @@ class SerializedProgram:
def __str__(self) -> str:
return bytes(self).hex()
def __repr__(self):
return "%s(%s)" % (self.__class__.__name__, str(self))
def __eq__(self, other) -> bool:
if not isinstance(other, SerializedProgram):
return False