From 2ae0376476855082121008b59633a25d7d5851ee Mon Sep 17 00:00:00 2001 From: Guillaume Marceau Date: Tue, 19 Jul 2011 12:59:46 -0400 Subject: [PATCH] Fixes the (cons an image empty) error message --- collects/lang/private/rewrite-error-message.rkt | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/collects/lang/private/rewrite-error-message.rkt b/collects/lang/private/rewrite-error-message.rkt index 8ac58a7340..1083fdcd7f 100755 --- a/collects/lang/private/rewrite-error-message.rkt +++ b/collects/lang/private/rewrite-error-message.rkt @@ -78,12 +78,18 @@ (lambda (all one) "expects a ")) (list #rx"list or cyclic list" (lambda (all) "list")) + (list (regexp-quote "given #(struct:object:image% ...)") + (lambda (all) "given an image")) + (list (regexp-quote "given #(struct:object:image-snip% ...)") + (lambda (all) "given an image")) + (list (regexp-quote "given #(struct:object:cache-image-snip% ...)") + (lambda (all) "given an image")) (list (regexp-quote "#(struct:object:image% ...)") - (lambda (all) "an image")) + (lambda (all) "(image)")) (list (regexp-quote "#(struct:object:image-snip% ...)") - (lambda (all) "an image")) + (lambda (all) "(image)")) (list (regexp-quote "#(struct:object:cache-image-snip% ...)") - (lambda (all) "an image")))) + (lambda (all) "(image)")))) (for/fold ([msg msg]) ([repl. replacements]) (regexp-replace* (first repl.) msg (second repl.))))