Opened 3 years ago

Closed 3 years ago

Last modified 22 months ago

#8749 closed bug (fixed)

Pattern synonyms crash GHCi

Reported by: monoidal Owned by:
Priority: normal Milestone: 7.8.1
Component: Compiler Version: 7.8.1-rc1
Keywords: PatternSynonyms Cc: cactus
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: #8757 Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


ghci -XPatternSynonyms
> let pattern P x = x

causes a panic. I understand pattern synonyms are currently unsupported in GHCi, but we should give an error message, not a panic.

Change History (7)

comment:1 Changed 3 years ago by cactus

The real problem seems to me to be the fact that local pattern synonym definitions are not rejected.

comment:2 Changed 3 years ago by cactus

  • Blocked By 8757 added

comment:3 Changed 3 years ago by Dr. ERDI Gergo <gergo@…>

In e0a55415545074bc7a757462624079f54f7785e2/ghc:

Issue an error for pattern synonyms defined in a local scope (#8757)

This also fixes the internal crash when using pattern synonyms
in GHCi (#8749)

comment:4 Changed 3 years ago by cactus

  • Status changed from new to merge

comment:5 Changed 3 years ago by monoidal

  • Milestone set to 7.8.1
  • Version changed from 7.7 to 7.8.1-rc1

comment:6 Changed 3 years ago by thoughtpolice

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

comment:7 Changed 22 months ago by cactus

  • Keywords PatternSynonyms added
Note: See TracTickets for help on using tickets.