all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* emacs refuses to save file in the same encoding it was read
@ 2003-10-10 20:08 Sam Steingold
  2003-10-14  0:52 ` Kenichi Handa
  2003-10-22  9:14 ` Juri Linkov
  0 siblings, 2 replies; 14+ messages in thread
From: Sam Steingold @ 2003-10-10 20:08 UTC (permalink / raw)


GNU Emacs 21.3.50.1 (i386-msvc-nt5.0.2195)
 of 2003-10-08 on WINSTEINGOLDLAP
--with-msvc (12.00)

I have a file which starts with this line:
;;; -*- coding: utf-8-unix -*-

it is opened and displayed by emacs correctly.
however, when I try to modify and save it, I get the following question:

Selected encoding mule-utf-8-unix disagrees with iso-2022-7bit specified
by file contents.  Really save (else edit coding cookies and try again)?
(y or n)

when I answer affirmatively, the file is saved, but a line
;; -*- coding: iso-2022-7bit; -*-
is added in front of my cookie.

what is going on?

My understanding is that since everything can be encoded with utf-8,
there is no reason for Emacs to suggest a different encoding.
I seem to remember that there are some identical characters - from the
unicode POV - which Emacs represents differently.
First, I thought this bug has been fixed already.
Second, I thought it was irrelevant here anyway: the file is read in
utf-8!

It appears that buffer-file-coding-system is somehow set to
iso-2022-7bit; I sets default value to utf-8.

-- 
Sam Steingold (http://www.podval.org/~sds) running w2k
<http://www.camera.org> <http://www.iris.org.il> <http://www.memri.org/>
<http://www.mideasttruth.com/> <http://www.honestreporting.com>
main(a){printf(a,34,a="main(a){printf(a,34,a=%c%s%c,34);}",34);}

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2003-10-26 18:52 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-10 20:08 emacs refuses to save file in the same encoding it was read Sam Steingold
2003-10-14  0:52 ` Kenichi Handa
2003-10-14  3:42   ` Pascal J.Bourguignon
2003-10-22  9:14 ` Juri Linkov
2003-10-22 12:43   ` Stefan Monnier
2003-10-22 15:17     ` Juri Linkov
2003-10-22 17:15       ` Stefan Monnier
2003-10-23 18:38   ` Richard Stallman
2003-10-23 19:15     ` Stefan Monnier
2003-10-24 10:42       ` Richard Stallman
2003-10-24 14:14         ` Stefan Monnier
2003-10-25 22:26           ` Richard Stallman
2003-10-26 18:52             ` Stefan Monnier
2003-10-23 19:27     ` Alan Shutko

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.