type definition with strict products
S. Doaitse Swierstra
doaitse@cs.uu.nl
Wed, 30 Jan 2002 16:52:10 +0100
--============_-1199716562==_ma============
Content-Type: text/plain; charset="us-ascii" ; format="flowed"
I a file that is too large to post here completely, I have used:
type Result val s = (# val, Steps s #)
and I get the error message:
UU_Parsing.hs:391:
Illegal unboxed tuple type as function argument: (# val, Steps s #)
In the type: (# val, Steps s #)
While checking the RHS of a type synonym declaration `Result'
In the type synonym declaration for `Result'
using version "The Glorious Glasgow Haskell Compilation System,
version 5.02.2".
Runningan earlier version of the compiler I get on the same file the
following error message:
ghc-5.00.2: panic! (the `impossible' happened, GHC version 5.00.2):
dsExpr: tuple pattern:
let {
fail_d9jc
= PrelErr.patError
@ (b r,
UU_Parsing.Steps a,
UU_Parsing.Steps a,
UU_Parsing.Exp a,
UU_Parsing.Steps a)
(PrelBase.unpackCString# "UU_Parsing.hs:735|case")
} in
case ds_d9iL of wild_B1 { (# v, ds_d9iR #) ->
case ds_d9iR of wild_B1 {
UU_Parsing.Best l m f r -> (v, l, m, f, r); __DEFAULT -> fail_d9jc
}
}
Please report it as a compiler bug to glasgow-haskell-bugs@haskell.org,
or http://sourceforge.net/projects/ghc/.
which is not very informative either.
My questions are:
- is this type definition really forbidden, and what does the phrase
"function argument " in the error message refer to?
- was there a restriction introduced about what one may write at the
rhs of a type defintion between version 5.00.2 and 5.02.2?
Thanks for looking into this,
Doaitse Swierstra
--
__________________________________________________________________________
S. Doaitse Swierstra, Department of Computer Science, Utrecht University
P.O.Box 80.089, 3508 TB UTRECHT, the Netherlands
Mail: mailto:doaitse@cs.uu.nl
WWW: http://www.cs.uu.nl/
tel: +31 30 253 3962
fax: +31 30 251 3791
mobile: +31 6 2880 1680
__________________________________________________________________________
--============_-1199716562==_ma============
Content-Type: text/html; charset="us-ascii"
<!doctype html public "-//W3C//DTD W3 HTML//EN">
<html><head><style type="text/css"><!--
blockquote, dl, ul, ol, li { padding-top: 0 ; padding-bottom: 0 }
--></style><title>type definition with strict
products</title></head><body>
<div>I a file that is too large to post here completely, I have
used:</div>
<div><br></div>
<div><font color="#FF0000">type Result val s = (# val, Steps s
#)</font><br>
</div>
<div>and I get the error message:</div>
<div><br></div>
<div><font color="#007700">UU_Parsing.hs:391:</font></div>
<div><font color="#007700"> Illegal unboxed tuple
type as</font><font color="#FF0000"> function argument</font><font
color="#007700">: (# val, Steps s #)<br>
In the type: (# val, Steps s #)<br>
While checking the RHS of a type synonym
declaration `Result'<br>
In the type synonym declaration for
`Result'</font></div>
<div><br></div>
<div>using version "The Glorious Glasgow Haskell Compilation
System, version 5.02.2".</div>
<div><br></div>
<div>Runningan earlier version of the compiler I get on the same file
the following error message:</div>
<div><font color="#007700">ghc-5.00.2: panic! (the `impossible'
happened, GHC version 5.00.2):<br>
dsExpr: tuple pattern:<br>
let {<br>
fail_d9jc<br>
= PrelErr.patError<br>
@ (b r,<br>
UU_Parsing.Steps a,<br>
UU_Parsing.Steps a,<br>
UU_Parsing.Exp a,<br>
UU_Parsing.Steps a)<br>
(PrelBase.unpackCString#
"UU_Parsing.hs:735|case")<br>
} in<br>
case ds_d9iL of wild_B1 { (# v, ds_d9iR #) -><br>
case ds_d9iR of wild_B1 {<br>
UU_Parsing.Best l m f r -> (v, l, m, f, r);
__DEFAULT -> fail_d9jc<br>
}<br>
}<br>
<br>
Please report it as a compiler bug to
glasgow-haskell-bugs@haskell.org,<br>
or http://sourceforge.net/projects/ghc/.</font></div>
<div><br></div>
<div>which is not very informative either.</div>
<div><br></div>
<div>My questions are:</div>
<div><br></div>
<div>- is this type definition really forbidden, and what does the
phrase "function argument " in the error message refer
to?</div>
<div><br></div>
<div>- was there a restriction introduced about what one may write at
the rhs of a type defintion between version 5.00.2 and
5.02.2?</div>
<div><br></div>
<div> Thanks for looking into this,</div>
<div> Doaitse Swierstra</div>
<div><br></div>
<div> </div>
<div><br></div>
<div><br></div>
<div><br></div>
<x-sigsep><pre>--
</pre></x-sigsep>
<div><font size="-1"
color="#000000"
>____________________________________________________________________<span
></span>______<br>
S. Doaitse Swierstra, Department of Computer Science, Utrecht
University</font></div>
<div><font size="-1"
color="#000000"
> <span
></span>
P.O.Box 80.089, 3508 TB UTRECHT, the Netherlands<br>
<span
></span>
Mail:
mailto:doaitse@cs.uu.nl <span
></span> <br>
<span
></span>
WWW: http://www.cs.uu.nl/</font></div>
<div><font size="-1" color="#000000"><br>
<span
></span>
tel: +31 30 253 3962</font></div>
<div><font size="-1"
color="#000000"
> <span
></span>
fax: +31 30 251 3791</font></div>
<div><font size="-1"
color="#000000"
> <span
></span>
mobile: +31 6 2880 1680<br>
_____________________________________________________________________<span
></span>_____</font></div>
</body>
</html>
--============_-1199716562==_ma============--