Daniel,<br><br>BTW, if i comment out the version of PutIn that calls HF{L,R}Val and put in the unit, instead, i see the complaint you're seeing. i'll upgrade ghc.<br><br>Best wishes,<br><br>--greg<br><br><div class="gmail_quote">
On Mon, Dec 15, 2008 at 2:49 PM, Greg Meredith <span dir="ltr"><<a href="mailto:lgreg.meredith@biosimilarity.com">lgreg.meredith@biosimilarity.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Daniel,<br><br>Thanks. i'm using<br><br>GHCi, version 6.8.2: <a href="http://www.haskell.org/ghc/" target="_blank">http://www.haskell.org/ghc/</a> :? for help<br>Loading package base ... linking ... done.<br>Prelude> :l monoidal.hs<br>
[1 of 1] Compiling Monoidal ( monoidal.hs, interpreted )<br> C-c C-cInterrupted.<br>> :q<br><br>Best wishes,<br><font color="#888888"><br>--greg</font><div><div></div><div class="Wj3C7c"><br><br><div class="gmail_quote">
On Mon, Dec 15, 2008 at 2:50 PM, Daniel Fischer <span dir="ltr"><<a href="mailto:daniel.is.fischer@web.de" target="_blank">daniel.is.fischer@web.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Am Montag, 15. Dezember 2008 23:16 schrieb Greg Meredith:<br>
> Haskellians,<br>
><br>
> An even simpler version <<a href="http://paste.pocoo.org/show/95518/" target="_blank">http://paste.pocoo.org/show/95518/</a>> that reveals<br>
<div>> the issue. i'm astounded that the compiler literally just hangs.<br>
><br>
> Best wishes,<br>
><br>
> --greg<br>
><br>
> On Mon, Dec 15, 2008 at 12:23 PM, Greg Meredith <<br>
><br>
> <a href="mailto:lgreg.meredith@biosimilarity.com" target="_blank">lgreg.meredith@biosimilarity.com</a>> wrote:<br>
> > Haskellians,<br>
> ><br>
> > The simple-minded and smallish code sample at this<br>
</div>> > link<<a href="http://paste.pocoo.org/show/95503/" target="_blank">http://paste.pocoo.org/show/95503/</a>>causes the compiler to go off<br>
<div>> > into never-never land. Any clues would be greatly appreciated.<br>
> ><br>
> > Best wishes,<br>
> ><br>
> > --greg<br>
<br>
</div>I can't confirm it, with 6.8.3:<br>
<br>
$ ghc -O2 --make Monoidal.hs<br>
[1 of 1] Compiling Monoidal ( Monoidal.hs, Monoidal.o )<br>
<br>
Monoidal.hs:110:11:<br>
Couldn't match expected type `i1'<br>
against inferred type `Isomorpism (HFTensorExpr a i) a'<br>
`i1' is a rigid type variable bound by<br>
the instance declaration at Monoidal.hs:103:42<br>
In the expression: (PutIn (\ a -> (HFTLVal a)))<br>
In the third argument of `HFTExpr', namely<br>
`[(PutIn (\ a -> (HFTLVal a)))]'<br>
In the expression:<br>
(HFTExpr<br>
(HFTLVal a)<br>
(HFTRVal b)<br>
[(PutIn (\ a -> (HFTLVal a)))]<br>
[(PutIn (\ b -> (HFTRVal b)))])<br>
$<br>
<br>
and the earlier version:<br>
<br>
$ ghc -O2 --make Monoidal2.hs<br>
[1 of 1] Compiling Monoidal2 ( Monoidal2.hs, Monoidal2.o )<br>
<br>
Monoidal2.hs:105:18:<br>
Couldn't match expected type `HFTensorExpr a i'<br>
against inferred type `[i1] -> [i1] -> HFTensorExpr a i1'<br>
In the expression: HFTExpr (HFTLVal a) (HFTRVal b)<br>
In the definition of `tMult':<br>
a tMult b = HFTExpr (HFTLVal a) (HFTRVal b)<br>
In the definition for method `tMult'<br>
<br>
Monoidal2.hs:122:10:<br>
Couldn't match expected type `[]' against inferred type `++ msa'<br>
Expected type: [i]<br>
Inferred type: ++ msa msb<br>
In the third argument of `HFTExpr', namely<br>
`((Shuffle<br>
(\ (HFTExpr (HFTExpr u v msu msv) w msuv msw)<br>
-> (tAssoc (HFTExpr (HFTExpr u v msu msv) w msuv msw)))) ::<br>
msa ++ msb)'<br>
In the expression:<br>
(HFTExpr<br>
(HFTExpr a b msa msb)<br>
c<br>
((Shuffle<br>
(\ (HFTExpr (HFTExpr u v msu msv) w msuv msw)<br>
-> (tAssoc (HFTExpr (HFTExpr u v msu msv) w msuv msw))))<br>
::<br>
msa ++ msb)<br>
msc)<br>
<br>
Monoidal2.hs:139:10:<br>
Couldn't match expected type `[]' against inferred type `++ msl'<br>
Expected type: [i]<br>
Inferred type: ++ msl msr<br>
In the third argument of `HFTExpr', namely<br>
`((Shuffle<br>
(\ (HFTExpr (HFTExpr a b msa msb) c msab msc)<br>
-> (tAssoc (HFTExpr (HFTExpr a b msa msb) c msab msc)))) ::<br>
msl ++ msr)'<br>
In the expression:<br>
(HFTExpr<br>
(HFTExpr l r msl msr)<br>
(HFTRVal b)<br>
((Shuffle<br>
(\ (HFTExpr (HFTExpr a b msa msb) c msab msc)<br>
-> (tAssoc (HFTExpr (HFTExpr a b msa msb) c msab msc))))<br>
::<br>
msl ++ msr)<br>
[(PutIn (\ b -> (HFTRVal b)))])<br>
<br>
Monoidal2.hs:150:11:<br>
Couldn't match expected type `i1'<br>
against inferred type `Isomorpism (HFTensorExpr a i) a'<br>
`i1' is a rigid type variable bound by<br>
the instance declaration at Monoidal2.hs:103:42<br>
In the expression: (PutIn (\ a -> (HFTRVal a)))<br>
In the third argument of `HFTExpr', namely<br>
`[(PutIn (\ a -> (HFTRVal a)))]'<br>
In the expression:<br>
(HFTExpr<br>
(HFTLVal a)<br>
(HFTRVal b)<br>
[(PutIn (\ a -> (HFTRVal a)))]<br>
[(PutIn (\ b -> (HFTRVal b)))])<br>
$<br>
<br>
No hang, which compiler version did you use?<br>
</blockquote></div><br><br clear="all"><br></div></div><div><div></div><div class="Wj3C7c">-- <br>L.G. Meredith<br>Managing Partner<br>Biosimilarity LLC<br>806 55th St NE<br>Seattle, WA 98105<br><br>+1 206.650.3740<br><br>
<a href="http://biosimilarity.blogspot.com" target="_blank">http://biosimilarity.blogspot.com</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>L.G. Meredith<br>Managing Partner<br>Biosimilarity LLC<br>806 55th St NE<br>Seattle, WA 98105<br><br>+1 206.650.3740<br><br><a href="http://biosimilarity.blogspot.com">http://biosimilarity.blogspot.com</a><br>