diff options
author | Thomas Winant <thomas.winant@cs.kuleuven.be> | 2014-11-28 16:08:10 -0600 |
---|---|---|
committer | Austin Seipp <austin@well-typed.com> | 2014-11-28 17:17:17 -0600 |
commit | d831b6f41b3b89dc4a643069d5668c05a20f3c37 (patch) | |
tree | 4f717db36c841619324cd210b9146ed8db671869 /compiler/main/ErrUtils.lhs | |
parent | 7460dafae3709218af651cb8bc47b5f03d4c25c7 (diff) | |
download | haskell-d831b6f41b3b89dc4a643069d5668c05a20f3c37.tar.gz |
Implement Partial Type Signatures
Summary:
Add support for Partial Type Signatures, i.e. holes in types, see:
https://ghc.haskell.org/trac/ghc/wiki/PartialTypeSignatures
This requires an update to the Haddock submodule.
Test Plan: validate
Reviewers: austin, goldfire, simonpj
Reviewed By: simonpj
Subscribers: thomie, Iceland_jack, dominique.devriese, simonmar, carter, goldfire
Differential Revision: https://phabricator.haskell.org/D168
GHC Trac Issues: #9478
Diffstat (limited to 'compiler/main/ErrUtils.lhs')
-rw-r--r-- | compiler/main/ErrUtils.lhs | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/compiler/main/ErrUtils.lhs b/compiler/main/ErrUtils.lhs index 12f484b421..61f433573b 100644 --- a/compiler/main/ErrUtils.lhs +++ b/compiler/main/ErrUtils.lhs @@ -14,7 +14,7 @@ module ErrUtils ( Messages, ErrorMessages, WarningMessages, errMsgSpan, errMsgContext, errMsgShortDoc, errMsgExtraInfo, mkLocMessage, pprMessageBag, pprErrMsgBag, pprErrMsgBagWithLoc, - pprLocErrMsg, makeIntoWarning, + pprLocErrMsg, makeIntoWarning, isWarning, errorsFound, emptyMessages, isEmptyMessages, mkErrMsg, mkPlainErrMsg, mkLongErrMsg, mkWarnMsg, mkPlainWarnMsg, @@ -137,6 +137,10 @@ mkLocMessage severity locn msg makeIntoWarning :: ErrMsg -> ErrMsg makeIntoWarning err = err { errMsgSeverity = SevWarning } +isWarning :: ErrMsg -> Bool +isWarning err + | SevWarning <- errMsgSeverity err = True + | otherwise = False -- ----------------------------------------------------------------------------- -- Collecting up messages for later ordering and printing. |