[GHC] #3640: NamedFieldPuns broken in where clauses
GHC
trac at galois.com
Fri Nov 6 06:08:36 EST 2009
#3640: NamedFieldPuns broken in where clauses
--------------------------------------------+-------------------------------
Reporter: cjs | Owner: igloo
Type: merge | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 6.12.1 RC1
Severity: major | Resolution:
Keywords: NamedFieldPuns | Difficulty: Unknown
Testcase: rename/should_compile/T3640 | Os: Linux
Architecture: x86_64 (amd64) |
--------------------------------------------+-------------------------------
Changes (by simonpj):
* testcase: => rename/should_compile/T3640
* owner: simonpj => igloo
* type: bug => merge
Comment:
Thank you for reporting this bug -- excellent catch. Fixed by
{{{
Thu Nov 5 08:55:25 PST 2009 simonpj at microsoft.com
* Fix Trac #3640, plus associated refactoring
In fixing this bug (to do with record puns), I had the usual rush of
blood to the head, and I did quite a bit of refactoring in the way
that duplicate/shadowed names are reported.
I think the result is shorter as well as clearer.
In one place I found it convenient for the renamer to use the ErrCtxt
carried in the monad. (The renamer used not to have such a context,
but years ago the typechecker and renamer monads became one, so now it
does.) So now it's availble if you want it in future.
M ./compiler/rename/RnBinds.lhs -73 +50
M ./compiler/rename/RnEnv.lhs -48 +45
M ./compiler/rename/RnExpr.lhs -10 +9
M ./compiler/rename/RnPat.lhs -3 +1
M ./compiler/rename/RnSource.lhs -34 +29
M ./compiler/rename/RnTypes.lhs -1 +1
M ./compiler/typecheck/TcRnMonad.lhs -32 +47
}}}
Ian, please merge this if it goes over smoothly, which I think it will.
Simon
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3640#comment:2>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list