From 431a520ed867cf82947a00650ef64dedaafbec51 Mon Sep 17 00:00:00 2001 From: Robby Findler Date: Wed, 14 Aug 2013 15:45:49 -0500 Subject: [PATCH] add error message with the right form name --- pkgs/gui-pkgs/gui-lib/unstable/2d/match.rkt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pkgs/gui-pkgs/gui-lib/unstable/2d/match.rkt b/pkgs/gui-pkgs/gui-lib/unstable/2d/match.rkt index d201ec859d..3f2d7b5354 100644 --- a/pkgs/gui-pkgs/gui-lib/unstable/2d/match.rkt +++ b/pkgs/gui-pkgs/gui-lib/unstable/2d/match.rkt @@ -67,4 +67,9 @@ [y (in-range 1 num-of-rows)]) #`[(#,(hash-ref coord-to-content (list x 0)) #,(hash-ref coord-to-content (list 0 y))) - (let () #,@(hash-ref coord-to-content (list x y)))]))))])) + (let () #,@(hash-ref coord-to-content (list x y)))]) + [(_ _) + (2dmatch-error #,@main-args)])))])) + +(define (2dmatch-error a b) + (error '2dmatch "no matching clauses for ~e and ~e" a b))