Opened 3 years ago

Closed 3 years ago

Last modified 2 years 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:

Description

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: newmerge

comment:5 Changed 3 years ago by monoidal

Milestone: 7.8.1
Version: 7.77.8.1-rc1

comment:6 Changed 3 years ago by thoughtpolice

Resolution: fixed
Status: mergeclosed

comment:7 Changed 2 years ago by cactus

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