From: "Mattias Engdegård" <mattiase@acm.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: 43632@debbugs.gnu.org
Subject: bug#43632: Raw bytes printed as latin-1 in echo area and *Messages*
Date: Sat, 26 Sep 2020 18:00:55 +0200 [thread overview]
Message-ID: <B1232A8B-D3C2-4066-AA32-4360316051CD@acm.org> (raw)
In-Reply-To: <83mu1cr5fn.fsf@gnu.org>
26 sep. 2020 kl. 16.14 skrev Eli Zaretskii <eliz@gnu.org>:
First, thank you for your quick answer.
> If you want to see escapes, set
> print-escape-nonascii non-nil.
Certainly, but that isn't needed when printing to a buffer, as in (prin1 "\377").
The print-escape-nonascii docs say
When the output goes in a multibyte buffer, this feature is
enabled regardless of the value of the variable.
Why, then, is the echo area not treated as a multibyte buffer in this regard? Is there a practical reason or is it an artefact of history that cannot be changed?
(Note that the echo area buffers, the minibuffer, and *Messages* are all multibyte.)
If the behaviour of (prin1 x t) cannot be changed, then what about eval-expression (M-|)? Being an interactive command, surely compatibility isn't an obstacle to making it more useful?
I'm assuming that it would be more useful to see raw bytes shown octal-escaped or otherwise visually distinct from their interpretation as Latin-1. If nothing else, it would make sense to have the same behaviour as when evaluating something in *scratch*.
It would also be interesting to know why, when print-escape-nonascii is nil, unibyte strings are decoded specifically as Latin-1 (and not, say, UTF-8). I presume it is an artefact of history.
next prev parent reply other threads:[~2020-09-26 16:00 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-26 12:51 bug#43632: Raw bytes printed as latin-1 in echo area and *Messages* Mattias Engdegård
2020-09-26 14:05 ` Andreas Schwab
2020-09-26 14:14 ` Eli Zaretskii
2020-09-26 14:22 ` Lars Ingebrigtsen
2020-09-26 14:26 ` Eli Zaretskii
2020-09-26 16:00 ` Mattias Engdegård [this message]
2020-09-26 16:10 ` Eli Zaretskii
2020-09-26 16:53 ` Mattias Engdegård
2020-09-26 16:57 ` Eli Zaretskii
2020-09-26 17:27 ` Eli Zaretskii
2020-09-27 10:58 ` Lars Ingebrigtsen
2020-09-27 11:05 ` Eli Zaretskii
2020-09-27 11:13 ` Lars Ingebrigtsen
2020-09-27 11:25 ` Eli Zaretskii
2020-09-27 11:36 ` Lars Ingebrigtsen
2020-09-27 11:43 ` Eli Zaretskii
2020-09-26 19:53 ` Mattias Engdegård
2020-09-27 5:56 ` 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=B1232A8B-D3C2-4066-AA32-4360316051CD@acm.org \
--to=mattiase@acm.org \
--cc=43632@debbugs.gnu.org \
--cc=eliz@gnu.org \
/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).