diff lisp/mule/make-coding-system.el @ 5128:7be849cb8828 ben-lisp-object

merge
author Ben Wing <ben@xemacs.org>
date Sun, 07 Mar 2010 02:09:59 -0600
parents 88f955fa5a7f
children 311f6817efc2 308d34e9f07d
line wrap: on
line diff
--- a/lisp/mule/make-coding-system.el	Fri Mar 05 04:08:17 2010 -0600
+++ b/lisp/mule/make-coding-system.el	Sun Mar 07 02:09:59 2010 -0600
@@ -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 ?\uE000
+  "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