X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2FbasicTypes%2FBasicTypes.lhs;h=f782da3e96751b808114c1fe28b9421a31070e66;hp=9d5b481285084ba30108505a6bdfcf375e1ca650;hb=cae75f82226638691cfa1e85fc168f4b65ddce4d;hpb=35c21b89f504b1db205c97d8a184d2e24a1f3cde diff --git a/compiler/basicTypes/BasicTypes.lhs b/compiler/basicTypes/BasicTypes.lhs index 9d5b481..f782da3 100644 --- a/compiler/basicTypes/BasicTypes.lhs +++ b/compiler/basicTypes/BasicTypes.lhs @@ -19,7 +19,7 @@ module BasicTypes( Arity, - DeprecTxt, + WarningTxt(..), Fixity(..), FixityDirection(..), defaultFixity, maxPrecedence, @@ -95,7 +95,14 @@ initialVersion = 1 \begin{code} -type DeprecTxt = FastString -- reason/explanation for deprecation +-- reason/explanation from a WARNING or DEPRECATED pragma +data WarningTxt = WarningTxt FastString + | DeprecatedTxt FastString + deriving Eq + +instance Outputable WarningTxt where + ppr (WarningTxt w) = doubleQuotes (ftext w) + ppr (DeprecatedTxt d) = text "Deprecated:" <+> doubleQuotes (ftext d) \end{code} %************************************************************************