
#8762: Panic involving unboxed tuples and phantom types ------------------------------------+------------------------------------- Reporter: josef | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.6.3 Keywords: | Operating System: Unknown/Multiple Architecture: Unknown/Multiple | Type of failure: None/Unknown Difficulty: Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | ------------------------------------+------------------------------------- I ran into a bug involving unboxed tuples and the following piece of code is an attempt at isolating the problem: {{{ {-# LANGUAGE UnboxedTuples #-} module Main where type Ty a = Int bug :: Ty a -> (# Ty a, () #) bug ty = (# ty, () #) main = do let (# a, b #) = bug undefined return () }}} It seems that the phantom type is necessary to trigger the bug. The bug is still present in 7.8rc1. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/8762 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler