Opened 5 years ago

Closed 5 years ago

#2901 closed merge (fixed)

GHC crashes with "impossible happened ... RnEnv.lookupImportedName" if using DisambiguateRecordFields and qualifiers

Reported by: spookylukey Owned by: igloo
Priority: normal Milestone:
Component: Compiler Version: 6.8.2
Keywords: Cc:
Operating System: Linux Architecture: Unknown/Multiple
Type of failure: Difficulty: Unknown
Test Case: rename/should_fail/T2901 Blocked By:
Blocking: Related Tickets:

Description

If you specify DisambiguateRecordFields? as an option, and then try to use qualifiers for field names in a data constructor, GHC crashes like this:

ghc-6.8.2: panic! (the 'impossible' happened)
  (GHC version 6.8.2 for i386-unknown-linux):
        RnEnv.lookupImportedName F.field{v}

See attached files for example -- simply do 'ghci Main.hs' to see the bug.

This bug means that if you use field disambiguation in part of a module, you have to use it everywhere in that module.

Attachments (2)

Foo.hs (53 bytes) - added by spookylukey 5 years ago.
Main.hs (70 bytes) - added by spookylukey 5 years ago.

Download all attachments as: .zip

Change History (5)

Changed 5 years ago by spookylukey

comment:1 Changed 5 years ago by spookylukey

Actually, the 'Foo.hs' file is not needed to reproduce the bug, just download Main.hs and attempt to open in ghci.

Changed 5 years ago by spookylukey

comment:2 Changed 5 years ago by simonpj

  • Difficulty set to Unknown
  • Owner set to igloo
  • Test Case set to rename/should_fail/T2901
  • Type changed from bug to merge

Fixed by

Tue Dec 30 07:04:45 PST 2008  simonpj@microsoft.com
  * Refactor RnEnv to fix Trac #2901

Pls merge

Simon

comment:3 Changed 5 years ago by igloo

  • Resolution set to fixed
  • Status changed from new to closed

Merged.

Note: See TracTickets for help on using tickets.