diff options
author | Jaro Reinders <jaro.reinders@gmail.com> | 2021-05-01 17:40:38 +0200 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-05-05 05:44:26 -0400 |
commit | f464e4777662a25c0b241d396146ba7a3182b9f3 (patch) | |
tree | 2bb8860a0c6f9d338996ce411710b124d7f7d91a /compiler/GHC/Rename/Module.hs | |
parent | e9617fbace826b048208c51e47d1552449675d57 (diff) | |
download | haskell-f464e4777662a25c0b241d396146ba7a3182b9f3.tar.gz |
More specific error messages for annotations (fixes #19740)
Diffstat (limited to 'compiler/GHC/Rename/Module.hs')
-rw-r--r-- | compiler/GHC/Rename/Module.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/GHC/Rename/Module.hs b/compiler/GHC/Rename/Module.hs index 1b54b53716..80384e56d8 100644 --- a/compiler/GHC/Rename/Module.hs +++ b/compiler/GHC/Rename/Module.hs @@ -35,7 +35,7 @@ import GHC.Rename.Utils ( HsDocContext(..), mapFvRn, bindLocalNames , newLocalBndrsRn , withHsDocContext, noNestedForallsContextsErr , addNoNestedForallsContextsErr, checkInferredVars ) -import GHC.Rename.Unbound ( mkUnboundName, notInScopeErr ) +import GHC.Rename.Unbound ( mkUnboundName, notInScopeErr, WhereLooking(WL_Global) ) import GHC.Rename.Names import GHC.Tc.Gen.Annotation ( annCtxt ) import GHC.Tc.Utils.Monad @@ -1347,7 +1347,7 @@ badRuleLhsErr name lhs bad_e text "LHS must be of form (f e1 .. en) where f is not forall'd" where err = case bad_e of - HsUnboundVar _ uv -> notInScopeErr (mkRdrUnqual uv) + HsUnboundVar _ uv -> notInScopeErr WL_Global (mkRdrUnqual uv) _ -> text "Illegal expression:" <+> ppr bad_e {- ************************************************************** |