[GHC] #9175: Bad interaction between Pattern Synonyms and Text
GHC
ghc-devs at haskell.org
Fri Jun 6 12:06:12 UTC 2014
#9175: Bad interaction between Pattern Synonyms and Text
---------------------------------------+-----------------------------------
Reporter: emertens | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 7.8.2
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: Compile-time crash | Unknown/Multiple
Test Case: | Difficulty: Unknown
Blocking: | Blocked By:
| Related Tickets:
---------------------------------------+-----------------------------------
Comment (by Simon Peyton Jones <simonpj@…>):
In [changeset:"7ac600d5fcd74db1f991555de6e415030970d5f3/ghc"]:
{{{
#!CommitTicketReference repository="ghc"
revision="7ac600d5fcd74db1f991555de6e415030970d5f3"
Make the matcher and wrapper Ids in PatSyn into LocalIds, not GlobalIds
This was a serious bug, exposed by Trac #9175. The matcher and wrapper
must be LocalIds, like record selectors and dictionary functions, for
the reasons now documented in Note [Exported LocalIds] in Id.lhs
In fixing this I found
- PatSyn should have an Id inside it (apart from the wrapper and matcher)
It should be a Name. Hence psId --> psName, with knock-on consequences
- Tidying of PatSyns in TidyPgm was wrong
- The keep-alive set in Desugar.deSugar (now) doesn't need pattern
synonyms
in it
I also cleaned up the interface to PatSyn a little, so there's a tiny
knock-on
effect in Haddock; hence the haddock submodule update.
It's very hard to make a test for this bug, so I haven't.
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9175#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list