From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Marius Vollmer Newsgroups: gmane.lisp.guile.user Subject: Re: functional hash operations Date: 01 Jan 2003 22:47:59 +0100 Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Message-ID: <877kdoh78w.fsf@zagadka.ping.de> References: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: main.gmane.org 1041457750 14533 80.91.224.249 (1 Jan 2003 21:49:10 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 1 Jan 2003 21:49:10 +0000 (UTC) Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18Tqjb-0003lm-00 for ; Wed, 01 Jan 2003 22:49:08 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18TqjQ-00075m-0C for guile-user@m.gmane.org; Wed, 01 Jan 2003 16:48:56 -0500 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 18Tqiv-0006vV-00 for guile-user@gnu.org; Wed, 01 Jan 2003 16:48:25 -0500 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 18Tqie-0005yI-00 for guile-user@gnu.org; Wed, 01 Jan 2003 16:48:15 -0500 Original-Received: from dialin.speedway42.dip71.dokom.de ([195.138.42.71] helo=zagadka.ping.de) by monty-python.gnu.org with smtp (Exim 4.10.13) id 18TqiX-0005aR-00 for guile-user@gnu.org; Wed, 01 Jan 2003 16:48:01 -0500 Original-Received: (qmail 18857 invoked by uid 1000); 1 Jan 2003 21:47:59 -0000 Original-To: guile-user@gnu.org In-Reply-To: Original-Lines: 25 User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: General Guile related discussions List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: main.gmane.org gmane.lisp.guile.user:1496 X-Report-Spam: http://spam.gmane.org/gmane.lisp.guile.user:1496 prj@po.cwru.edu (Paul Jarc) writes: > Sometimes it would be useful to have functional operations on hashes: > "make a copy of this hash which also has this additional entry", etc. > It would also be nice to make such copies share as much memory as > possible with the original hash. This is easy enough to do by taking > advantage of the knowledge of the representation of hashes as vectors > of alists, but is it safe to assume that representation? Or might the > representation change in the future? The hash table implementation should be considered opaque (except for the handles) and if you want to play it safe, you should only use the procedures from the reference manual with them. Would it be workable to implement functional hash tables from scratch, without basing them on the builtin implementation? There are the functions 'hash', 'hashv', and 'hashq' to help with computing hash values for Scheme objects. Or, as Thien-Thi has said, you can lobby the Guile developers to include the things you need. A working patch (also for the manual) is quite convincing. -- GPG: D5D4E405 - 2F9B BCCC 8527 692A 04E3 331E FAF8 226A D5D4 E405 _______________________________________________ Guile-user mailing list Guile-user@gnu.org http://mail.gnu.org/mailman/listinfo/guile-user