bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#51037: [PATCH] Make `print-level` & `print-length` customizable in E


From: Lars Ingebrigtsen
Subject: bug#51037: [PATCH] Make `print-level` & `print-length` customizable in ERT batch tests
Date: Mon, 25 Oct 2021 15:05:07 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Michael <sp1ff@runbox.com> writes:

> The issue: stack traces are printed by the `backtrace`
> package. backtrace.el was authored by Gemini (which is why I've
> added him to this thread). backtrace.el doesn't directly work in
> terms of `print-le{ngth,vel}`: it defines a custom variable
> `backtrace-line-length` and then adjusts print-level &
> print-length in let bindings in order to:
>
>  1. try to respect the desired line length
>  2. not trigger bug 31919 (Lisp Debugger doesn't work when at
>  stack limit)

[...]

> For myself, I was quite surprised to all learn this: I had to
> spend a fair bit of time digging through the source to find out
> what was happening to my settings for print-length &
> print-level.

Yeah, I didn't remember `backtrace-line-length' either.  Perhaps it
should be linked to from the doc strings of print-length and
print-level... 

> My personal incliniation is to remove the `backtrace-line-length`
> variable entirely, and make the `debug` package responsible for
> controlling print-level so as to avoid 31919. But that's me: is
> there a compelling use-case for backtrace.el working in terms of
> limiting line length rather than just using `print-le{ve,ength}`?

Well...  if we're talking in an ert context, it could increase both the
backtrace-line-length and max-lisp-eval-depth variables when gathering
the backtrace, I think?

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

[Prev in Thread] Current Thread [Next in Thread]