Common Lisp programmers are blessed with the awesome SLIME development environment for Emacs; but sadly Schemers have nothing comparable. There are a few SLIME backends for various Schemes around, in varying states of completeness, but as far as I can tell none for my Scheme implementation of choice: Chicken Scheme.

Therefore I present swank-chicken: a SWANK server written in Chicken Scheme. (SWANK is the protocol SLIME uses to talk to the inferior Lisp process.) I’ve been hacking it together over the past week or two and it’s now reached the point where it is more or less usable. Click on the screenshot below for an example:

Supported features so far:

REPL support with input/output (i.e. read and write work as expected)

Complile region and load file commands (e.g. C-c C-l, C-c C-c)

Basic SLDB support with back trace

Parameter argument hints in the minibuffer

Huge swathes of SLIME features are obviously missing at the moment, but the most useful ones are there. In particular, I think it’s at least as functional as the normal inferior-scheme mode. The most significant omission at the moment is support for interrupting Scheme evaluation from Emacs – C-c C-c at the REPL will currently kill the backend process completely. Naïvely this should be implemented in the same way as the debugger-abort command: by calling the top-level continuation. However, perhaps unsurprisingly, calling a continuation from a Scheme SIGINT handler turns out to be a bad idea. So if you have a runaway process you must kill and restart it with C-c C-c M-x slime-restart-inferior-lisp.

~~~ chicken scheme investigator ~~~
ongoing story arc follows its struggles with having a slightly gimpy right leg, caused by injury with a farming implement. it was sustained whilst leading a botched escape attempt from captivity of which it was the only survivor. now HAUNTED with GUILT, it attempts to absolve itself through solving nefarious crimes against chicken-kind.

blodgett had completely forgotten about this post. upon this rediscovery, it must now confess it was party to the killing of a cockerel over the holiday period, which was subsequently converted into a curry. possibly blodgett should turn itself in before the vengeful investigator discovers its misdemeanours… :O

I installed the latest slime-version (2012-04-11) and the error message disappeared. I have tried the following features which also work for me:
– C-c C-c
– C-c C-l
– Hint-text in the mini-buffer showing the command structure

However autocompletion is still not working! I have installed the provided chicken-egg “slime”. At the moment, my .emacs-configuration-file looks as follows:

The documentation is only supported in the CSI-interpreter. It is not available in opened scheme-files. Maybe this is not supported.
Does chicken-slime also support a pretty printer mode, which supports tidying up the scheme code?