From: simonpj Date: Wed, 23 Jul 2003 13:08:55 +0000 (+0000) Subject: [project @ 2003-07-23 13:08:55 by simonpj] X-Git-Tag: Approx_11550_changesets_converted~658 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=9bb32dd2adae0a71b558b366bb73c4d4771ef80a;hp=49bff3215bf3fe9ada24dac2cf80f97db4e597dd;p=ghc-hetmet.git [project @ 2003-07-23 13:08:55 by simonpj] Comments and cosmetics about dataTcOccs --- 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