[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[MIT-Scheme-devel] hash-table/modify! and hash-table/intern!
From: |
Taylor R Campbell |
Subject: |
[MIT-Scheme-devel] hash-table/modify! and hash-table/intern! |
Date: |
Wed, 25 May 2011 18:09:41 +0000 |
User-agent: |
IMAIL/1.21; Edwin/3.116; MIT-Scheme/9.1 |
Currently these usually look like:
(hash-table/modify! hash-table key
(lambda (datum)
...
here goes
a big, horrible
hairy, gigantic
expression
...)
tiny)
(hash-table/intern! hash-table key
;; Gotta cons a closure here.
(lambda ()
(make-foo key)))
I'd rather that they look like:
(hash-table/modify! hash-table key tiny
(lambda (datum)
big huge horrible hairy expression))
(hash-table/intern! hash-table key make-foo)
Currently they're not documented, so maybe we can get away with
changing them. Alexey has been threatening to update the hash table
documentation, and even sent me some patches, so now seems like a good
time. Incidentally, there's even a (vestigial) redefinition in
edwin/nntp.scm of HASH-TABLE/MODIFY! with the argument order I prefer.
Comments? Flames?
(The real problem is that we don't have any reasonable way to handle
API and ABI compatibility. Some day, perhaps...)
- [MIT-Scheme-devel] hash-table/modify! and hash-table/intern!,
Taylor R Campbell <=