From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Luc Teirlinck Newsgroups: gmane.emacs.devel Subject: Re: char-table-range Date: Fri, 20 Feb 2004 18:03:11 -0600 (CST) Sender: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Message-ID: <200402210003.i1L03Bo05498@raven.dms.auburn.edu> References: <200402160043.JAA17207@etlken.m17n.org> <200402160130.i1G1UKG04241@raven.dms.auburn.edu> <200402190128.i1J1StG21175@raven.dms.auburn.edu> NNTP-Posting-Host: deer.gmane.org X-Trace: sea.gmane.org 1077321993 24525 80.91.224.253 (21 Feb 2004 00:06:33 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 21 Feb 2004 00:06:33 +0000 (UTC) Cc: emacs-devel@gnu.org, handa@m17n.org Original-X-From: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Sat Feb 21 01:06:21 2004 Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1AuKez-0006dI-00 for ; Sat, 21 Feb 2004 01:06:21 +0100 Original-Received: from monty-python.gnu.org ([199.232.76.173]) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1AuKez-0001Al-00 for ; Sat, 21 Feb 2004 01:06:21 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.30) id 1AuKed-0000TY-GI for emacs-devel@quimby.gnus.org; Fri, 20 Feb 2004 19:05:59 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.30) id 1AuKe7-0008KI-Cu for emacs-devel@gnu.org; Fri, 20 Feb 2004 19:05:27 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.30) id 1AuKdE-0006nS-EZ for emacs-devel@gnu.org; Fri, 20 Feb 2004 19:05:04 -0500 Original-Received: from [131.204.53.104] (helo=manatee.dms.auburn.edu) by monty-python.gnu.org with esmtp (Exim 4.30) id 1AuKcW-0005iH-Nh; Fri, 20 Feb 2004 19:03:48 -0500 Original-Received: from raven.dms.auburn.edu (raven.dms.auburn.edu [131.204.53.29]) by manatee.dms.auburn.edu (8.12.10/8.12.10) with ESMTP id i1L03hKt022991; Fri, 20 Feb 2004 18:03:43 -0600 (CST) Original-Received: (from teirllm@localhost) by raven.dms.auburn.edu (8.11.6+Sun/8.11.6) id i1L03Bo05498; Fri, 20 Feb 2004 18:03:11 -0600 (CST) X-Authentication-Warning: raven.dms.auburn.edu: teirllm set sender to teirllm@dms.auburn.edu using -f Original-To: rms@gnu.org In-reply-to: (message from Richard Stallman on Fri, 20 Feb 2004 08:42:21 -0500) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.2 Precedence: list List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+emacs-devel=quimby.gnus.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:20087 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:20087 Richard Stallman wrote: The second thing that looks _somewhat_ strange (but maybe it is OK) is that (make-char-table subtype init) will also set extra slots to INIT. This is somewhat unexpected because a logical default for characters would seldom seem to make sense for extra slots as well. Maybe this is intentional anyway. It looks like a misfeature to me. But before changing it, we had better see if anything depends on it. I think that means looking at all the calls to make-char-table and checking each one. Can you do that? It seems to be used (?) in exactly one place in the Emacs source code (if I did not overlook anything): china-util.el There we find the function `expand-euc-big5-alist' which is defined inside an eval-when-compile and it is normally not defined at runtime. It contains the line: (let ((chartable (make-char-table 'translation-table #xFF)) `chartable' is used in the return value. This sets all values, including extra slots to #xFF = 255. `expand-euc-big5-alist' is used to put a translation-table property on the symbol `big5-to-cns' (whose actual value as a variable is another translation table). The value of that translation-table property has its two extra slots set to 255. Ielm run illustrating the above: ===File ~/china-util-ielm=================================== *** Welcome to IELM *** Type (describe-mode) for help. ELISP> (load "china-util") t ELISP> (setq tt (get 'big5-to-cns 'translation-table)) ;; Long ouput omitted ELISP> (char-table-extra-slot tt 0) 255 ELISP> (char-table-extra-slot tt 1) 255 ELISP> (expand-euc-big5-alist nil) *** Eval error *** Symbol's function definition is void: expand-euc-big5-alist ELISP> (load "china-util.el") t ELISP> (expand-euc-big5-alist nil) #^[t 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 ! 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 nil translation-table 255 255] ELISP> ============================================================