A Mad Club
Lambda Calculus — Call us a mad club
James A Crippen on comp.lang.scheme
Programming in Scheme is the most fun I've had programming since my days doing Smalltalk. In point of fact, it is the language I go to first when I need to develop code where no obvious toolkit already exists. Of course "obvious" means different thigns to different people, but for me it usually means no GUI, uncomplicated network protocols and relatively sane data formats. In short, I use Scheme for the computational heavy-lifting in my projects.
Over the years, a lot of my past Scheme work has accumulated here. Some of it is still useful, some of it is dead (mostly due to bit-rot). I have also been involved in some Standards work. You can peruse the code below.
- Logging Framework
This is a logging framework I've had in use for a few years packaged as a single source file for Larceny Scheme. The only Larceny-specific bits pertain to the use of mutexes (which follow Gambit's API and are non-functional stubs in this version) and to the FFI which is used in implementing open/append/close logging to named files.
- ICD9 to XML
icd9-2-sxml.scm is a program which reads the plain text (converted from the RTF version in the zip file) of the International Classification of Diseases, 9th Revision, Clinical Modification and converts it into SXML and, of course, vanilla XML. The SXML data is obviously the preferred format.
In case you missed the links above:
- Web Scraper
Two implementations from R. Kent Dybvig's PhD thesis, titled Three Implementation Models for Scheme, specifically the heap and stack based models. The code from the paper is heavily plagiarized, but completely adapted to modern Schemes (specifically RRS compatibles). I have added support for primitive operations inherited from the host Scheme, but I have not otherwise expanded the language implemented by Dybvig.
Why only two? Why bother at all?
The first question is easy. The third model in the paper was clearly a requirement from his thesis advisor, who wanted support for the fancy hardware he was designing (and which I have never heard anything about elsewhere). The other question's answer is...kinda lame, really. I need a reliable (meaning consistent across Scheme implementations)
evalfunction for S2. This code doesn't really get me there, but I thought it might when I started. It was instructive for bringing together all the ideas I've read about implementing Scheme-like languages. Maybe I'll finally get around to building my own...
- BBDB Reader
This code is the beginning of a vaguely-defined project which will help me manage my email more gracefully. Essentially, the goal is to offload all email processing from the Gnus (
nnmlfor Gnus geeks) back-end onto an NNTP/IMAP/Custom-protocol server implemented in Scheme. One of the most vaguely-defined parts is how to incoporate all the data-mining smarts I've developed over the last year into the standard messaging protocols.
- Scatter/Gather Daemon
This is a lovely little hack which distributes queries off to a list of servers and coalesces their responses back into a single datastream. The code strongly leverages Scsh's extended port interface and support for sockets to effectively use Scheme data as a network protocol.
This is a binary file editor; sort of inspired by
dd, but made more user-friendly (Hah!), at least for small edits. I use it for hacking the
savegame.*files in Command & Conquer.
Bulky is a bulk emailing program for Unix. It's more convenient for me to use a bulk email approach in announcing updates to this web site (including new newsletters) than to use a mailing list manager like Majordomo. It's also rather easier to configure; you just need a text file listing all the email addresses to which you want your email sent.
You can download the Scsh source code and build it quite easily. Just
make install. Unfortunately there is no documentation, but the program is so simple that the
usagemessage should be good enough.
The Version Control System to end my frustrations with CVS. Development has been stalled for a while, but it sortof works and there's a cool XEmacs client for it.
- "S-squared" a Scheme->Scheme compiler. Well, more of a preprocessor at the moment. The goal is to take any Scheme's module system and produce a single, loadable, fully macro-expanded, r5rs-compliant source module. It may also provide escaping continuations and EVAL as I have (possibly half-baked) implementation strategies for these. Right now S2 supports Bigloo source modules, but there are hooks for Scheme48, SLIB and Guile just waiting to be exploited.
VSCM is an older implementation of Scheme, originally written by Matthias Blume. Alas, he has moved on to bigger and better things, but he has given me permission to put VSCM up on SourceForge and resume development of the platform. And I do have plans:
- Finite ring arithmetics
- Scsh primitives
- Bug fixes
- Native Compilation
- Decent debugging facilities
That should keep me busy for at least a little while...
- "TeX and Scheme" a new version of TeX reimplemented in Scheme, and with Scheme available for use in TeX macros. If you read the TeX source code, it is really obvious that it is fifteen year old code. Fortunately Don Knuth is a consummate programmer as well as a great mathematician and bit-rot hasn't yet destroyed the program. However, I find its current state incomprehensible. It's also almost completely unmodifiable (Don't even get me started about Web change files), and who hasn't thought that there must be a better way to write TeX macros? I aim to fix all of these problems. Currently the code is very incomplete, because, since I decided to host it on Stalin, I've been taking a detour building S2.
|Copyright © 2001 by David Rush|