unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: Eli Zaretskii <eliz@gnu.org>
Cc: monnier@iro.umontreal.ca, 12925@debbugs.gnu.org,
	ethan.glasser.camp@gmail.com
Subject: bug#12925: 24.1; string-make-unibyte instead of string-as-unibyte
Date: Wed, 02 Jun 2021 07:07:25 +0200	[thread overview]
Message-ID: <87r1hkam7m.fsf@gnus.org> (raw)
In-Reply-To: <83fsy123yg.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 01 Jun 2021 14:56:39 +0300")

Eli Zaretskii <eliz@gnu.org> writes:

> Why not make both methods do the same: insert the bytes of the
> multibyte text into the unibyte buffer?

I think it's still common to have raw bytes in multibyte buffers.
Inserting data from these buffers into unibyte buffers works fine.
(That's the rationale for inserting the "lower byte" in these
situations.)

So I don't think we should change this to insert the multibyte text,
because that'd break stuff.

The question is what to do when inserting multibyte characters in
unibyte buffers, and I think that's always an error (i.e., it's never
what the person who wrote the code wanted to happen).  I think we should
start off by doing a demoted warning thing, and then segue into
signalling an error at a later date.

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





  parent reply	other threads:[~2021-06-02  5:07 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-18 17:45 bug#12925: 24.1; string-make-unibyte instead of string-as-unibyte Ethan Glasser-Camp
2012-11-19  2:27 ` Stefan Monnier
2021-06-01  7:02   ` Lars Ingebrigtsen
2021-06-01 11:56     ` Eli Zaretskii
2021-06-01 13:45       ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-06-01 14:03         ` Eli Zaretskii
2021-06-01 14:25           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-06-01 15:26             ` Eli Zaretskii
2021-06-02  5:07       ` Lars Ingebrigtsen [this message]
2021-06-02 12:07         ` Eli Zaretskii
2021-06-02 13:09           ` Lars Ingebrigtsen
2021-06-02 13:36             ` 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=87r1hkam7m.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=12925@debbugs.gnu.org \
    --cc=eliz@gnu.org \
    --cc=ethan.glasser.camp@gmail.com \
    --cc=monnier@iro.umontreal.ca \
    /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).