[racket-dev] teaching language error messages

From: Guillaume Marceau (gmarceau at gmail.com)
Date: Tue Jul 19 13:03:53 EDT 2011

On Tue, Jul 19, 2011 at 12:03 PM, Robby Findler <robby at eecs.northwestern.edu
> wrote:

> I see that the teaching language error messages now have things like
> this in them (where the . is an image literal):
> Welcome to DrRacket, version [3m].
> Language: Beginning Student; memory limit: 128 MB.
> > (+ 1 (list .))
> +: expects a number as 2nd argument, given (cons an image empty)
> I see that this is being done via regexps on the error message
> strings. This seems bad.
> Can we at least get some delimiters on there so it doesn't look like a
> malformed use of 'cons'?

My goal is to have the actual image displayed there instead. "an image" was
just a quick replacement for #(struct:object:cache-image-snip% ...), which
is incomprehensible to students, and intimidating.

I've push a fix that makes it read (cons (image) empty) instead. That should
hold us up until we get a proper image there.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/dev/archive/attachments/20110719/ab53eea2/attachment.html>

Posted on the dev mailing list.