unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Stefan Monnier <monnier@iro.umontreal.ca>
To: Eli Zaretskii <eliz@gnu.org>
Cc: emacs-devel@gnu.org
Subject: Re: Obsolete string-to-multibyte hard to replace
Date: Tue, 30 May 2017 00:03:08 -0400	[thread overview]
Message-ID: <jwvmv9vgfix.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: <83fufnftf8.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 29 May 2017 20:45:47 +0300")

>> I think it'd make sense to change make-string so it always returns
>> a multibyte string, and maybe to also introduce a new make-unibyte-string.
> How about an optional argument to make-string instead?

You mean (make-string N CHAR &optional UNIBYTE) so it returns
multibyte by default (for all chars) unless the new optional arg is provided?
Sounds fine, yes.

> Anyway, beware of the use case of building and starting Emacs in a
> non-ASCII directory, especially when the locale's codeset is not
> UTF-8.  If we make such changes, these use cases must be audited to
> see that they still work, because we use unibyte strings during early
> stages of startup in these cases, until we figure out how to decode
> them.

The likelihood that those code-paths use make-string is fairly low, but
of course, it can't be ruled out.


        Stefan



  reply	other threads:[~2017-05-30  4:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-29 13:01 Obsolete string-to-multibyte hard to replace Stefan Monnier
2017-05-29 17:45 ` Eli Zaretskii
2017-05-30  4:03   ` Stefan Monnier [this message]
2017-05-30  0:21 ` Noam Postavsky
2017-05-30  3:28   ` Stefan Monnier

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=jwvmv9vgfix.fsf-monnier+emacs@gnu.org \
    --to=monnier@iro.umontreal.ca \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@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).