diff options
-rw-r--r-- | Lib/repr.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Lib/repr.py b/Lib/repr.py index 8a86682..53b5207 100644 --- a/Lib/repr.py +++ b/Lib/repr.py @@ -111,8 +111,7 @@ class Repr: # Bugs in x.__repr__() can cause arbitrary # exceptions -- then make up something except: - return '<' + x.__class__.__name__ + ' instance at ' + \ - hex(id(x))[2:] + '>' + return '<%s instance at %x>' % (x.__class__.__name__, id(x)) if len(s) > self.maxstring: i = max(0, (self.maxstring-3)//2) j = max(0, self.maxstring-3-i) |