Subject: Re: bug#69056: 30.0.50; history-add-new-input and recursive minibuffers

From: Eli Zaretskii <[email-masked]>
Date: Thu, 15 Feb 2024 21:34:09 +0200

> Cc: [email-masked]
> Date: Thu, 15 Feb 2024 14:20:08 -0500
> From:  Stefan Monnier via "Bug reports for GNU Emacs,
>  the Swiss army knife of text editors" <[email-masked]>
> 
> >> Why not use `Vhistory_add_new_input`?
> > Good question, I guess for some reason I assumed that `NILP (Vfoo)`
> > doesn't check the buffer-local value like `find_symbol_value (Qfoo)`
> > does...
> 
> The handling of Vfoo is quite delicate, but it does give you the value
> in the current-buffer (i.e. they're changed as needed whenever we go
> through `set_buffer`).
> 
> > Oh, that's much simpler indeed.  And it seems to work just as well.
> > Here's an updated patch (v2):
> 
> LGTM.
> Eli&Stefan, any objection?

Yes, see my other message.  I feel like we are making an effort to
change the internals, which runs the usual risk of breaking things,
for very little gain.  The more general issue with let-binding
variables around APIs that enter the minibuffer stays, so I see little
sense to fix just this one problem in an incomplete way that could on
top of that break existing code.