[commit: ghc] ghc-7.10: ApiAnnotations : parens around a context with wildcard loses annotations (adb21a8)
git at git.haskell.org
git at git.haskell.org
Fri May 22 13:09:30 UTC 2015
Repository : ssh://git@git.haskell.org/ghc
On branch : ghc-7.10
Link : http://ghc.haskell.org/trac/ghc/changeset/adb21a824540f2bbacd67006d9a29da2aee66026/ghc
>---------------------------------------------------------------
commit adb21a824540f2bbacd67006d9a29da2aee66026
Author: Alan Zimmerman <alan.zimm at gmail.com>
Date: Thu May 21 15:05:48 2015 +0200
ApiAnnotations : parens around a context with wildcard loses annotations
Summary:
In the following code, the extra set of parens around the context end up
with detached annotations.
{-# LANGUAGE PartialTypeSignatures #-}
module ParensAroundContext where
f :: ((Eq a, _)) => a -> a -> Bool
f x y = x == y
Trac ticket #10354
It turns out it was the TupleTy that was the culprit.
This may also solve #10315
Test Plan: ./validate
Reviewers: hvr, austin, goldfire
Reviewed By: austin
Subscribers: goldfire, bgamari, thomie, mpickering
Differential Revision: https://phabricator.haskell.org/D868
GHC Trac Issues: #10354, #10315
(cherry picked from commit 0df14b5db06751f817d3ba794cc74ac54519b5b8)
>---------------------------------------------------------------
adb21a824540f2bbacd67006d9a29da2aee66026
compiler/parser/Parser.y | 10 +--
compiler/parser/RdrHsSyn.hs | 18 +++--
testsuite/tests/ghc-api/annotations/.gitignore | 1 +
testsuite/tests/ghc-api/annotations/Makefile | 8 ++
testsuite/tests/ghc-api/annotations/T10278.stdout | 16 ++--
testsuite/tests/ghc-api/annotations/T10354.stderr | 3 +
testsuite/tests/ghc-api/annotations/T10354.stdout | 90 ++++++++++++++++++++++
testsuite/tests/ghc-api/annotations/Test10354.hs | 14 ++++
testsuite/tests/ghc-api/annotations/all.T | 1 +
.../ghc-api/annotations/{t10278.hs => t10354.hs} | 2 +-
10 files changed, 141 insertions(+), 22 deletions(-)
Diff suppressed because of size. To see it, use:
git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc adb21a824540f2bbacd67006d9a29da2aee66026
More information about the ghc-commits
mailing list