#7323: decoding GADTs gives internal error: stg_ap_v_ret
---------------------------+------------------------------------------------
Reporter: heisenbug | Owner:
Type: bug | Status: new
Priority: normal | Component: Compiler
Version: 7.7 | Keywords:
Os: Linux | Architecture: x86_64 (amd64)
Failure: Runtime crash | Testcase: yes
Blockedby: | Blocking:
Related: |
---------------------------+------------------------------------------------
Changes (by heisenbug):
* cc: ggreif@… (added)
Comment:
I found a pre-7.4 compiler: ghc-7.4.0.20111220
it emits:
`internal-error: Impossible case alternative`
The other compiler did not even typecheck the test case:
{{{
ghc-7.5.20120713 internal-error.lhs
[1 of 1] Compiling Main ( internal-error.lhs, internal-error.o
)
internal-error.lhs:39:23:
Couldn't match type `BL.ByteString'
with
`bytestring-0.10.0.0:Data.ByteString.Lazy.Internal.ByteString'
Expected type: [ByteString]
->
bytestring-0.10.0.0:Data.ByteString.Lazy.Internal.ByteString
Actual type: [ByteString] -> BL.ByteString
In the second argument of `(.)', namely `BL.fromChunks'
In the expression: decode . BL.fromChunks
In an equation for `decodeAs': decodeAs = decode . BL.fromChunks
internal-error.lhs:45:41:
Couldn't match expected type `BL.ByteString'
with actual type
`bytestring-0.10.0.0:Data.ByteString.Lazy.Internal.ByteString'
In the first argument of `BL.toChunks', namely `lazy'
In the second argument of `($)', namely `BL.toChunks lazy'
In the expression: decodeAs $ BL.toChunks lazy
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7323#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs