diff options
author | Vladislav Zavialov <vlad.z.4096@gmail.com> | 2022-10-25 17:05:46 +0400 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-10-26 00:02:01 -0400 |
commit | 0270cc54481bef9630274e77c2750940c1a4eff5 (patch) | |
tree | 36375e6f74da495ca308f1d060cd30aad4f4fb24 /testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr | |
parent | f7bfb40c9010ff34d301c9cf8c805261699daad5 (diff) | |
download | haskell-0270cc54481bef9630274e77c2750940c1a4eff5.tar.gz |
Introduce TcRnWithHsDocContext (#22346)
Before this patch, GHC used withHsDocContext to attach an HsDocContext
to an error message:
addErr $ mkTcRnUnknownMessage $ mkPlainError noHints (withHsDocContext ctxt msg)
The problem with this approach is that it only works with
TcRnUnknownMessage. But could we attach an HsDocContext to a
structured error message in a generic way? This patch solves
the problem by introducing a new constructor to TcRnMessage:
data TcRnMessage where
...
TcRnWithHsDocContext :: !HsDocContext -> !TcRnMessage -> TcRnMessage
...
Diffstat (limited to 'testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr')
-rw-r--r-- | testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr b/testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr index 718f136e46..4b2d2872c1 100644 --- a/testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr +++ b/testsuite/tests/partial-sigs/should_fail/WildcardInInstanceHead.stderr @@ -1,4 +1,4 @@ WildcardInInstanceHead.hs:7:14: error: [GHC-65507] - Wildcard ‘_’ not allowed - in an instance declaration + • Wildcard ‘_’ not allowed + • In an instance declaration |