diff lisp/mule/make-coding-system.el @ 5081:baffa6ca776a

Backed out changeset c673987f5f3d
author Aidan Kehoe <kehoea@parhasard.net>
date Fri, 26 Feb 2010 15:22:15 +0000
parents c673987f5f3d
children 88f955fa5a7f
line wrap: on
line diff
--- a/lisp/mule/make-coding-system.el	Mon Feb 22 21:26:18 2010 -0600
+++ b/lisp/mule/make-coding-system.el	Fri Feb 26 15:22:15 2010 +0000
@@ -2,7 +2,6 @@
 ;;; much of the implementation of the fixed-width coding system type.
 
 ;; Copyright (C) 2009 Free Software Foundation
-;; Copyright (C) 2010 Ben Wing.
 
 ;; Author: Aidan Kehoe
 
@@ -27,6 +26,13 @@
 
 ;;; Code:
 
+(defvar fixed-width-private-use-start (decode-char 'ucs #xE000)
+  "Start of a 256 code private use area for fixed-width coding systems.
+
+This is used to ensure that distinct octets on disk for a given coding
+system map to distinct XEmacs characters, preventing spurious changes when
+a file is read, not changed, and then written.  ")
+
 (defun fixed-width-generate-helper (decode-table encode-table
 				   encode-failure-octet)
   "Helper func, `fixed-width-generate-encode-program-and-skip-chars-strings',
@@ -317,7 +323,7 @@
   (check-argument-type #'listp unicode-map)
   (let ((decode-table (make-vector 256 nil))
         (encode-table (make-hash-table :size 256 :rehash-threshold 0.999))
-	(private-use-start #xE000)
+	(private-use-start (encode-char fixed-width-private-use-start 'ucs))
         (invalid-sequence-code-point-start
          (eval-when-compile
            (char-to-unicode