all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Kenichi Handa <handa@m17n.org>
To: Eric Hanchrow <eric.hanchrow@gmail.com>
Cc: 10383@debbugs.gnu.org
Subject: bug#10383: 24.0.91; (prefer-coding-system 'utf-8-with-signature) breaks the world
Date: Wed, 28 Dec 2011 17:07:43 +0900	[thread overview]
Message-ID: <tl7ipl15dbk.fsf@m17n.org> (raw)
In-Reply-To: <CAHZoxq8wxViADRk+rgq5eWEwNcB8FV-F5sxbZLjqjfMtDwgVOg@mail.gmail.com> (message from Eric Hanchrow on Tue, 27 Dec 2011 14:23:58 -0800)

In article <CAHZoxq8wxViADRk+rgq5eWEwNcB8FV-F5sxbZLjqjfMtDwgVOg@mail.gmail.com>, Eric Hanchrow <eric.hanchrow@gmail.com> writes:

> Type the following in *scratch*, then C-x C-e:
>      (prefer-coding-system 'utf-8-with-signature)
> Now type C-x d.
> You'll see an error:
>         Cannot open load file: dired
> You will soon find that your emacs is entirely broken, since no files
> can be loaded.

This is because utf-8-with-signature is recognized as ASCII
compatible and thus default-file-coding-system is also set
to it.  I've just committed a fix to make
utf-8-with-signature not ASCII compatible.  Please try
again with the latest trunk code.

By the way, as a result, now

    (prefer-coding-system 'utf-8-with-signature)

does not change default-file-coding-system.  I'm not sure
what is the intention of preferring utf-8-with-signature,
one may want default-file-coding-system be set to utf-8 in
such a case.  But, doing that automatically is too
heuristic.  Another possibility is that what actually wanted
is such a coding as utf-8-with-signature-on-decoding-only
(i.e. on decoding, BOM is recognized, but on encoding, don't
produce BOM).

---
Kenichi Handa
handa@m17n.org





  reply	other threads:[~2011-12-28  8:07 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-27 22:23 bug#10383: 24.0.91; (prefer-coding-system 'utf-8-with-signature) breaks the world Eric Hanchrow
2011-12-28  8:07 ` Kenichi Handa [this message]
2011-12-28  8:51   ` Eli Zaretskii
2011-12-28 10:49   ` Stefan Monnier
2011-12-29 23:27   ` Eric Hanchrow

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

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=tl7ipl15dbk.fsf@m17n.org \
    --to=handa@m17n.org \
    --cc=10383@debbugs.gnu.org \
    --cc=eric.hanchrow@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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.