summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorAlan Zimmerman <alan.zimm@gmail.com>2021-05-16 14:58:45 +0100
committerMarge Bot <ben+marge-bot@smart-cactus.org>2021-05-23 02:07:36 -0400
commit406cd90b8863da640a9835d5d9972fff1c18dcd7 (patch)
tree7b287e1ce76efbbe9910734d4f4b5d7952815251 /utils
parent0b1eed74e8ad5194152ed656ac3e4a547726b70a (diff)
downloadhaskell-406cd90b8863da640a9835d5d9972fff1c18dcd7.tar.gz
EPA: AnnAt missing for type application in patterns
Ensure that the exact print annotations accurately record the `@` for code like tyApp :: Con k a -> Proxy a tyApp (Con @kx @ax (x :: Proxy ax)) = x :: Proxy (ax :: kx) Closes #19850
Diffstat (limited to 'utils')
-rw-r--r--utils/check-exact/ExactPrint.hs4
-rw-r--r--utils/check-exact/Main.hs3
2 files changed, 5 insertions, 2 deletions
diff --git a/utils/check-exact/ExactPrint.hs b/utils/check-exact/ExactPrint.hs
index 8bcc508288..b4e53efeb6 100644
--- a/utils/check-exact/ExactPrint.hs
+++ b/utils/check-exact/ExactPrint.hs
@@ -3794,7 +3794,9 @@ instance ExactPrint (Pat GhcPs) where
instance ExactPrint (HsPatSigType GhcPs) where
getAnnotationEntry = const NoEntryVal
- exact (HsPS _ ty) = markAnnotated ty
+ exact (HsPS an ty) = do
+ markAnnKw an id AnnAt
+ markAnnotated ty
-- ---------------------------------------------------------------------
diff --git a/utils/check-exact/Main.hs b/utils/check-exact/Main.hs
index 807ab7290b..4316f2bea0 100644
--- a/utils/check-exact/Main.hs
+++ b/utils/check-exact/Main.hs
@@ -189,7 +189,8 @@ _tt = testOneFile changers "/home/alanz/mysrc/git.haskell.org/worktree/exactprin
-- "../../testsuite/tests/printer/Test19814.hs" Nothing
-- "../../testsuite/tests/printer/Test19821.hs" Nothing
-- "../../testsuite/tests/printer/Test19834.hs" Nothing
- "../../testsuite/tests/printer/Test19840.hs" Nothing
+ -- "../../testsuite/tests/printer/Test19840.hs" Nothing
+ "../../testsuite/tests/printer/Test19850.hs" Nothing
-- cloneT does not need a test, function can be retired