From: Lars Ingebrigtsen <larsi@gnus.org>
To: Francis Wright <francis.j.wright@gmail.com>
Cc: f.j.wright@live.co.uk, 30529@debbugs.gnu.org
Subject: bug#30529: 26.0.91; minibuffer errors change standard-output
Date: Thu, 26 Nov 2020 14:52:21 +0100 [thread overview]
Message-ID: <874klcql7u.fsf@gnus.org> (raw)
In-Reply-To: <85po510xv9.fsf@gmail.com> (Francis Wright's message of "Mon, 19 Feb 2018 16:04:26 +0000")
Francis Wright <francis.j.wright@gmail.com> writes:
> A user-error in the minibuffer can change the value of standard-output
> (to t) within the environment that invoked the minibuffer, whereas I
> think the minibuffer should rebind standard-output locally and not
> change its global value. Here is a simple way to illustrate this
> problem. Evaluate the following:
>
> (defun STANDARD-LISP ()
> "Run Standard LISP with input via the minibuffer and output via a buffer."
> (interactive)
> (switch-to-buffer (get-buffer-create "*Standard LISP*"))
> (let (value
> (standard-output (current-buffer)))
> (while t
> (terpri)
> (princ "Eval: ")
> (setq value (read))
> ;; (read) errors change standard-output to *Messages* buffer,
> ;; so...
> ;; (setq standard-output (current-buffer))
> (prin1 value) (terpri)
> (setq value (eval value))
> (terpri)
> (princ "====> ") (princ value) (terpri))))
(This bug report unfortunately got no response at the time.)
This problem is still present in Emacs 28. I tried following the code
logic for a couple of minutes to see just what it is that's (re)setting
`standard-output' here, but was unable to locate the location.
Anybody know?
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2020-11-26 13:52 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-19 16:04 bug#30529: 26.0.91; minibuffer errors change standard-output Francis Wright
2020-11-26 13:52 ` Lars Ingebrigtsen [this message]
2020-11-29 15:29 ` Basil L. Contovounesios
2020-11-30 9:41 ` Lars Ingebrigtsen
2021-08-12 14:34 ` Lars Ingebrigtsen
2021-08-12 15:04 ` Andreas Schwab
2021-08-13 11:22 ` Lars Ingebrigtsen
2021-08-12 15:58 ` Eli Zaretskii
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=874klcql7u.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=30529@debbugs.gnu.org \
--cc=f.j.wright@live.co.uk \
--cc=francis.j.wright@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).