Ticket #1932 (closed bug)

Opened 5 years ago

Last modified 5 years ago

:print in ghci: impossible happened

Reported by: joerisamson Owned by:
Priority: normal Milestone:
Component: GHCi Version: 6.8.1
Keywords: Cc:
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: Difficulty: Unknown
Test Case: Blocked By:
Blocking: Related Tickets:

Description

GHCi, version 6.8.1: http://www.haskell.org/ghc/  :? for help
Loading package base ... linking ... done.
Prelude> let fac n = foldl (*) 1 [1..n]
Prelude> :print fac
fac = <function>
ghc-6.8.1: panic! (the 'impossible' happened)
  (GHC version 6.8.1 for i386-unknown-linux):
        ghci/Debugger.hs:84:11-72: Irrefutable pattern failed for pattern Data.Maybe.Just subst


Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug

This also happens with:

Prelude> let sum' a b = a+b
Prelude> let product' a b = a*b
Prelude> let sum' a b = (+) a b

but not with:

Prelude> let sum a b = a
Prelude> :print sum
sum = <function>
Prelude> let summ a b = id b
Prelude> :print summ
summ = <function>
Prelude> let id' x = x
Prelude> :print id'
id' = <function>
Prelude> let product' = (*)
Prelude> :print product'
product' = <function>
Prelude> let sum' = (+)
Prelude> :print sum'
sum' = <function>

All these functions do work properly when used in expressions

Change History

Changed 5 years ago by sorear

  • difficulty set to Unknown

Thank you for the report, and the work you've done to narrow it down. Given the constraints you give, I'm extremely confident this is a dup of < http://hackage.haskell.org/trac/ghc/ticket/1827> - can you reproduce your this with the latest GHC HEAD?

Changed 5 years ago by joerisamson

  • summary changed from :type in ghci: impossible happened to :print in ghci: impossible happened

Changed 5 years ago by joerisamson

  • status changed from new to closed

I cannot reproduce this with GHC HEAD.

Changed 5 years ago by simonmar

  • architecture changed from Unknown to Unknown/Multiple

Changed 5 years ago by simonmar

  • os changed from Unknown to Unknown/Multiple
Note: See TracTickets for help on using tickets.