diff options
author | Alan Zimmerman <alan.zimm@gmail.com> | 2022-07-01 12:52:29 +0100 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-08-11 16:19:57 -0400 |
commit | ff67c79ee742024ca0ef41a9a7e540e1662d46bd (patch) | |
tree | 6588e16a80e86696f7541c483a724903b82ad492 /compiler/GHC/Rename/Bind.hs | |
parent | 5c24b1b3a9d6a4c2f471fd7d8ec65141a8b46357 (diff) | |
download | haskell-ff67c79ee742024ca0ef41a9a7e540e1662d46bd.tar.gz |
EPA: DotFieldOcc does not have exact print annotations
For the code
{-# LANGUAGE OverloadedRecordUpdate #-}
operatorUpdate f = f{(+) = 1}
There are no exact print annotations for the parens around the +
symbol, nor does normal ppr print them.
This MR fixes that.
Closes #21805
Updates haddock submodule
Diffstat (limited to 'compiler/GHC/Rename/Bind.hs')
-rw-r--r-- | compiler/GHC/Rename/Bind.hs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/compiler/GHC/Rename/Bind.hs b/compiler/GHC/Rename/Bind.hs index 5ade2db117..f69091c92d 100644 --- a/compiler/GHC/Rename/Bind.hs +++ b/compiler/GHC/Rename/Bind.hs @@ -70,6 +70,8 @@ import GHC.Data.Maybe ( orElse ) import GHC.Data.OrdList import qualified GHC.LanguageExtensions as LangExt +import Language.Haskell.Syntax.Basic (FieldLabelString(..)) + import Control.Monad import Data.Foldable ( toList ) import Data.List ( partition, sortBy ) @@ -710,7 +712,7 @@ rnPatSynBind sig_fn bind@(PSB { psb_id = L l name RecCon vars -> do { checkDupRdrNames (map (foLabel . recordPatSynField) vars) ; fls <- lookupConstructorFields name - ; let fld_env = mkFsEnv [ (flLabel fl, fl) | fl <- fls ] + ; let fld_env = mkFsEnv [ (field_label $ flLabel fl, fl) | fl <- fls ] ; let rnRecordPatSynField (RecordPatSynField { recordPatSynField = visible , recordPatSynPatVar = hidden }) |