Subject: Re: bug#25122: 24.5; function describe-variable hangs on large variables

From: Stefan Monnier <[email-masked]>
Date: Sat, 11 Mar 2017 10:33:44 -0500

> Actually, it's the indent-sexp on the whole object that takes time.
> Possibly we could sacrifice some indentation correctness if the printed
> representation is big.

Actually, I think that trying to optimize this is bound to fail: we want
*Help* to show up "instantly", so we're off by a factor of more
than 100, which seems way out of reach (unless there's really an
algorithmic problem in our code, admittedly).

I think the better way out is to do less work.  E.g. bound the total
amount printed (and replace the rest with "..." that can be expanded on
demand).

        Stefan