X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2Frename%2FRnSource.lhs;h=041a34c022eb5bb0f53c2883d00609521f090397;hb=732f30c21c984cf2a03afca3df91fa539c354559;hp=b7b4f0b87ded290e2d742140e09ddf1953cc405b;hpb=f01ea859e2b902ad0401b9012baae0a8ad0c2adf;p=ghc-hetmet.git diff --git a/compiler/rename/RnSource.lhs b/compiler/rename/RnSource.lhs index b7b4f0b..041a34c 100644 --- a/compiler/rename/RnSource.lhs +++ b/compiler/rename/RnSource.lhs @@ -280,7 +280,7 @@ rnHsForeignDecl (ForeignImport name ty spec) rnHsForeignDecl (ForeignExport name ty spec) = lookupLocatedOccRn name `thenM` \ name' -> rnHsTypeFVs (fo_decl_msg name) ty `thenM` \ (ty', fvs) -> - returnM (ForeignExport name' ty' spec, fvs ) + returnM (ForeignExport name' ty' spec, fvs `addOneFV` unLoc name') -- NB: a foreign export is an *occurrence site* for name, so -- we add it to the free-variable list. It might, for example, -- be imported from another module @@ -797,8 +797,8 @@ rnFamily (tydecl@TyFamily {tcdFlavour = flavour, emptyFVs) } } where - isDataFlavour (DataFamily _) = True - isDataFlavour _ = False + isDataFlavour DataFamily = True + isDataFlavour _ = False family_doc tycon = text "In the family declaration for" <+> quotes (ppr tycon) needOneIdx = text "Type family declarations requires at least one type index"