X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=compiler%2FbasicTypes%2FBasicTypes.lhs;h=f782da3e96751b808114c1fe28b9421a31070e66;hb=aa9a4f1053d3c554629a2ec25955e7530c95b892;hp=9d5b481285084ba30108505a6bdfcf375e1ca650;hpb=4f8f7ea99adce81a9545d080ad519392c4a0450d;p=ghc-hetmet.git 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} %************************************************************************