[GHC] #9077: Forcing the type to be IO {} instead of IO() causes a "panic! The impossible has happened" output.
GHC
ghc-devs at haskell.org
Mon May 5 10:28:36 UTC 2014
#9077: Forcing the type to be IO {} instead of IO() causes a "panic! The
impossible has happened" output.
-------------------------+-------------------------------------------------
Reporter: | Owner:
Westycoot | Status: new
Type: bug | Milestone:
Priority: | Version: 7.8.2
normal | Operating System: Unknown/Multiple
Component: | Type of failure: Compile-time performance bug
Compiler | Test Case:
Keywords: | Blocking:
Architecture: x86 |
Difficulty: |
Unknown |
Blocked By: |
Related Tickets: |
-------------------------+-------------------------------------------------
Below is the source code in which the bug occurs. It is easily reproduce-
able, by having the type be IO{} instead of IO().
When ran, this code will produce the "panic! The impossible has happened"
output. Which told me to report the bug here.
By changing IO() to IO{} (which I did by accident), no exception is
thrown, it simply tells the user to panic!
{{{
main :: IO {}
main = do
e1 <- getLine
e2 <- getLine
print ((read e1) + (read e2))
}}}
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/9077>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list