Opened 5 years ago

Closed 5 years ago

#7701 closed bug (duplicate)

compiler exception when -> is used instead of => in instance definition

Reported by: erantapaa Owned by:
Priority: normal Milestone:
Component: Compiler Version: 7.4.2
Keywords: Cc:
Operating System: MacOS X Architecture: x86
Type of failure: Compile-time crash Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


When running ghci on the attached file, the following exception is raised:

*** Exception: compiler/rename/RnSource.lhs:430:14-81: Irrefutable pattern failed for pattern Data.Maybe.Just (inst_tyvars,
                                                        SrcLoc.L _ cls,

It seems to stem from accidentally using -> instead of => in the following instance definition:

instance (ListConcat xs ys zs) -> ListConcat (x ::: xs) ys (x ::: zs)
  where listConcat = undefined

Attachments (1)

bug2.hs (508 bytes) - added by erantapaa 5 years ago.
example code

Download all attachments as: .zip

Change History (2)

Changed 5 years ago by erantapaa

Attachment: bug2.hs added

example code

comment:1 Changed 5 years ago by monoidal

Resolution: duplicate
Status: newclosed

Thanks for the report. The bug is fixed in GHC 7.6, see #5951.

Note: See TracTickets for help on using tickets.