From 795c86daa4afb53f7ec99f5082e2e7fcc690830c Mon Sep 17 00:00:00 2001 From: "audreyt@audreyt.org" Date: Tue, 12 Sep 2006 12:09:42 +0000 Subject: [PATCH] Take away XXXs in GADT records related code that are no longer TODOs. --- compiler/basicTypes/MkId.lhs | 8 ++++---- compiler/parser/ParserCore.y | 2 +- compiler/typecheck/TcTyClsDecls.lhs | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/compiler/basicTypes/MkId.lhs b/compiler/basicTypes/MkId.lhs index 172f8b0..0c430da 100644 --- a/compiler/basicTypes/MkId.lhs +++ b/compiler/basicTypes/MkId.lhs @@ -413,10 +413,10 @@ type (e.g. 'b' in T2). \begin{code} --- XXX - autrijus - --- Plan: 1. Determine naughtiness by comparing field type vs result type --- 2. Install naughty ones with selector_ty of type _|_ and fill in mzero for info --- 3. If it's not naughty, do the normal plan. +-- Steps for handling "naughty" vs "non-naughty" selectors: +-- 1. Determine naughtiness by comparing field type vs result type +-- 2. Install naughty ones with selector_ty of type _|_ and fill in mzero for info +-- 3. If it's not naughty, do the normal plan. mkRecordSelId :: TyCon -> FieldLabel -> Id mkRecordSelId tycon field_label diff --git a/compiler/parser/ParserCore.y b/compiler/parser/ParserCore.y index a9669b2..f2d48da 100644 --- a/compiler/parser/ParserCore.y +++ b/compiler/parser/ParserCore.y @@ -107,7 +107,7 @@ con :: { LConDecl RdrName } : d_pat_occ attv_bndrs hs_atys { noLoc $ ConDecl (noLoc (mkRdrUnqual $1)) Explicit $2 (noLoc []) (PrefixCon $3) ResTyH98} | d_pat_occ '::' ty - -- XXX - autrijus - $3 needs to be split into argument and return types! + -- XXX - audreyt - $3 needs to be split into argument and return types! -- also not sure whether the [] below (quantified vars) appears. -- also the "PrefixCon []" is wrong. -- also we want to munge $3 somehow. diff --git a/compiler/typecheck/TcTyClsDecls.lhs b/compiler/typecheck/TcTyClsDecls.lhs index cf9900a..75d582e 100644 --- a/compiler/typecheck/TcTyClsDecls.lhs +++ b/compiler/typecheck/TcTyClsDecls.lhs @@ -630,7 +630,7 @@ checkValidTyCon tc get_fields con = dataConFieldLabels con `zip` repeat con -- dataConFieldLabels may return the empty list, which is fine - -- XXX - autrijus - Make this far more complex to acommodate + -- Note: The complicated checkOne logic below is there to accomodate -- for different return types. Add res_ty to the mix, -- comparing them in two steps, all for good error messages. -- Plan: Use Unify.tcMatchTys to compare the first candidate's -- 1.7.10.4