From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Richard Stallman Newsgroups: gmane.emacs.devel Subject: Re: emacs and guile (Re: ehelp woes, or why I hate a module that I love so much) Date: Sun, 21 Jul 2002 14:14:50 -0600 (MDT) Sender: emacs-devel-admin@gnu.org Message-ID: <200207212014.g6LKEoI00844@aztec.santafe.edu> References: <20020704135240.4CBB.LEKTU@terra.es> <20020704164911.4CC1.LEKTU@terra.es> <200207181456.g6IEu0J25108@aztec.santafe.edu> <200207191654.g6JGsfu27015@aztec.santafe.edu> <87d6tjshgv.fsf@zagadka.ping.de> <200207200035.g6K0Z9U27888@aztec.santafe.edu> <878z46k3se.fsf@zagadka.ping.de> Reply-To: rms@gnu.org NNTP-Posting-Host: localhost.gmane.org X-Trace: main.gmane.org 1027282550 28928 127.0.0.1 (21 Jul 2002 20:15:50 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Sun, 21 Jul 2002 20:15:50 +0000 (UTC) Cc: raeburn@raeburn.org, emacs-devel@gnu.org Return-path: Original-Received: from quimby.gnus.org ([80.91.224.244]) by main.gmane.org with esmtp (Exim 3.33 #1 (Debian)) id 17WN7N-0007WT-00 for ; Sun, 21 Jul 2002 22:15:49 +0200 Original-Received: from fencepost.gnu.org ([199.232.76.164]) by quimby.gnus.org with esmtp (Exim 3.12 #1 (Debian)) id 17WNKs-0006ag-00 for ; Sun, 21 Jul 2002 22:29:46 +0200 Original-Received: from localhost ([127.0.0.1] helo=fencepost.gnu.org) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17WN7D-0003JR-00; Sun, 21 Jul 2002 16:15:39 -0400 Original-Received: from pele.santafe.edu ([192.12.12.119]) by fencepost.gnu.org with esmtp (Exim 3.35 #1 (Debian)) id 17WN6V-0003Cv-00; Sun, 21 Jul 2002 16:14:55 -0400 Original-Received: from aztec.santafe.edu (aztec [192.12.12.49]) by pele.santafe.edu (8.11.6+Sun/8.11.6) with ESMTP id g6LKEwB22548; Sun, 21 Jul 2002 14:14:58 -0600 (MDT) Original-Received: (from rms@localhost) by aztec.santafe.edu (8.10.2+Sun/8.9.3) id g6LKEoI00844; Sun, 21 Jul 2002 14:14:50 -0600 (MDT) X-Authentication-Warning: aztec.santafe.edu: rms set sender to rms@aztec using -f Original-To: mvo@zagadka.ping.de In-Reply-To: <878z46k3se.fsf@zagadka.ping.de> (message from Marius Vollmer on 20 Jul 2002 14:00:17 +0200) Errors-To: emacs-devel-admin@gnu.org X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.0.11 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: Emacs development discussions. List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.emacs.devel:5950 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:5950 Ok. However, we have only two sizes of Scheme cells: 2 words and 4 words. (Non-immediate objects are implemented by pointers to such a cell.) Most of the Emacs misc objects are 4 words or less. Can Scheme's 4-word types be used for them? What part of that 4 words is used for specifying the data type more precisely? One very important type, the marker, needs 5 words as currently defined. More precisely, it contains a buffer, a chain of markers pointer, two kinds of buffer positions (integers), and a bit flag. We could use a list to record the markers in a buffer instead of chaining them together; that would cost one extra word per marker, which is ok. Then the marker would use 3 words and one bit. Could the 4-word object be used for this? An Emacs Lisp symbol has 3 slots of meaning: value, function, and plist. It also has its name and the mechanism of interning it; I suppose Scheme symbols already have something equivalent to that. Does this mean we don't need any more slots in a symbol? Emacs Lisp allows multiple obarrays, but we might be able to dispense with that feature, since (I think) only abbrevs use it. (Does anyone know of other uses?) However, uninterned symbols are used in more places I think. Is there anything like an uninterned symbol in Scheme? A Lisp symbol also has a couple of flag bits, one for "variable alias" (which says this variable is an alias for another variable) and one for "constant" (it is an error to try to set this variable). There are a few data types that appear only in the value cell of a symbol, and indicate special ways to get and set the value. For instance, one says "this is a buffer-local variable" and another says "the value is stored in a certain address." These flag bits and forwarding values have a lot in common, and we could implement them with a single mechanism. But what mechanism?