Subject: bug#26650: 26.0.50; Protect *Backtrace* from accidental killing

From: Tino Calancha <[email-masked]>
Date: Wed, 26 Apr 2017 22:57:23 +0900 (JST)

On Wed, 26 Apr 2017, [email-masked] wrote:

> Eli Zaretskii <[email-masked]> writes:
>
>>>>> +  (add-hook 'kill-buffer-hook
>>>>> +            (lambda () (if (> (recursion-depth) 0) (top-level))) nil t)
>>>>
>>>> This will throw to top-level when _any_ buffer is killed, as long as
>>>> we are in recursive-edit, no?
>>> No, because `add-hook' is called with non-nil LOCAL arg.
>>
>> Right, sorry for not paying attention.
>
> Maybe I should have written
>
>    (add-hook 'kill-buffer-hook (lambda ...) nil 'local)
>
> to emphasize this?  I'm still undecided on the general style question of
> whether to use t or '<symbol> in these cases.
This reminds me the discussion here:
https://github.com/bbatsov/emacs-lisp-style-guide/issues/30