X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Fmain%2FTidyPgm.lhs;h=86e55f9e0654c891e702223398c8554cbdd5d274;hb=1187e57fab2b5904a808ac973e5d04b91f880920;hp=ef3864b7ad589019540eedf0d1536589ba64a9f6;hpb=cb9e4b09b94913465cee27a68a384ff8e20aa191;p=ghc-hetmet.git diff --git a/ghc/compiler/main/TidyPgm.lhs b/ghc/compiler/main/TidyPgm.lhs index ef3864b..86e55f9 100644 --- a/ghc/compiler/main/TidyPgm.lhs +++ b/ghc/compiler/main/TidyPgm.lhs @@ -21,7 +21,7 @@ import VarEnv import VarSet import Var ( Id, Var ) import Id ( idType, idInfo, idName, idCoreRules, isGlobalId, - isExportedId, mkVanillaGlobal, isLocalId, + isExportedId, mkVanillaGlobal, isLocalId, isNaughtyRecordSelector, idArity, idCafInfo, idUnfolding, isImplicitId, setIdInfo ) import IdInfo {- loads of stuff -} @@ -383,7 +383,10 @@ getImplicitBinds type_env where implicit_con_ids tc = mapCatMaybes dataConWrapId_maybe (tyConDataCons tc) - other_implicit_ids (ATyCon tc) = tyConSelIds tc + other_implicit_ids (ATyCon tc) = filter (not . isNaughtyRecordSelector) (tyConSelIds tc) + -- The "naughty" ones are not real functions at all + -- They are there just so we can get decent error messages + -- See Note [Naughty record selectors] in MkId.lhs other_implicit_ids (AClass cl) = classSelIds cl other_implicit_ids other = []