Commit d0ec8043 authored by Guido van Rossum's avatar Guido van Rossum

short_repr(): when processing tuple elements, use short_repr()

recursively to avoid blowing up when a tuple contains a really long
string (e.g. 100 MB in size).
parent a834963d
...@@ -57,7 +57,7 @@ def short_repr(obj): ...@@ -57,7 +57,7 @@ def short_repr(obj):
elts = [] elts = []
size = 0 size = 0
for elt in obj: for elt in obj:
r = repr(elt) r = short_repr(elt)
elts.append(r) elts.append(r)
size += len(r) size += len(r)
if size > REPR_LIMIT: if size > REPR_LIMIT:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment