From 9e3e71c70ad057c2ee13abf2b17aeb0a6742118e Mon Sep 17 00:00:00 2001 From: Neil Brown Date: Thu, 2 Apr 2009 15:42:02 +0000 Subject: [PATCH] Added a bit of extra help when a name is not found (suggesting other names) --- frontends/ParseOccam.hs | 1 + 1 file changed, 1 insertion(+) diff --git a/frontends/ParseOccam.hs b/frontends/ParseOccam.hs index 27a0f74..2a698f4 100644 --- a/frontends/ParseOccam.hs +++ b/frontends/ParseOccam.hs @@ -396,6 +396,7 @@ findName thisN thisNT (origN, origNT) <- case lookup (A.nameName thisN) (csLocalNames st) of Nothing -> dieP (A.nameMeta thisN) $ "name " ++ A.nameName thisN ++ " not defined" + ++ "; possibilities were: " ++ show (map fst (csLocalNames st)) Just def -> return def if thisNT /= origNT then dieP (A.nameMeta thisN) $ "expected " ++ show thisNT ++ " (" ++ A.nameName origN ++ " is " ++ show origNT ++ ")"