From 9bb32dd2adae0a71b558b366bb73c4d4771ef80a Mon Sep 17 00:00:00 2001 From: simonpj Date: Wed, 23 Jul 2003 13:08:55 +0000 Subject: [PATCH] [project @ 2003-07-23 13:08:55 by simonpj] Comments and cosmetics about dataTcOccs --- ghc/compiler/rename/RnEnv.lhs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ghc/compiler/rename/RnEnv.lhs b/ghc/compiler/rename/RnEnv.lhs index 255356c..84d0f69 100644 --- a/ghc/compiler/rename/RnEnv.lhs +++ b/ghc/compiler/rename/RnEnv.lhs @@ -483,9 +483,13 @@ lookupOrigName rdr_name dataTcOccs :: RdrName -> [RdrName] -- If the input is a data constructor, return both it and a type -- constructor. This is useful when we aren't sure which we are --- looking at +-- looking at. +-- +-- ToDo: If the user typed "[]" or "(,,)", we'll generate an Exact RdrName, +-- and we don't have a systematic way to find the TyCon's Name from +-- the DataCon's name. Sigh dataTcOccs rdr_name - | isDataOcc occ = [rdr_name, rdr_name_tc] + | isDataOcc occ = [rdr_name_tc, rdr_name] | otherwise = [rdr_name] where occ = rdrNameOcc rdr_name -- 1.7.10.4