<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:verdana, helvetica, sans-serif;font-size:10pt"><div>whoops!  wow, wrong message to reply to... please disregard the previous.</div><div><br></div><div>Apologies,</div><div>~Mark Snyder</div><div style="font-family:verdana, helvetica, sans-serif;font-size:10pt"><br><div style="font-family:arial, helvetica, sans-serif;font-size:13px">----- Original Message ----<br>From: "haskell-cafe-request@haskell.org" &lt;haskell-cafe-request@haskell.org><br>To: haskell-cafe@haskell.org<br>Sent: Thursday, September 25, 2008 12:13:22 PM<br>Subject: Haskell-Cafe Digest, Vol 61, Issue 49<br><br>Send Haskell-Cafe mailing list submissions to<br>    <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br><br>To subscribe or unsubscribe via the World Wide Web, visit<br>    <a
 href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br>or, via email, send a message with subject or body 'help' to<br>    <a ymailto="mailto:haskell-cafe-request@haskell.org" href="mailto:haskell-cafe-request@haskell.org">haskell-cafe-request@haskell.org</a><br><br>You can reach the person managing the list at<br>    <a ymailto="mailto:haskell-cafe-owner@haskell.org" href="mailto:haskell-cafe-owner@haskell.org">haskell-cafe-owner@haskell.org</a><br><br>When replying, please edit your Subject line so it is more specific<br>than "Re: Contents of Haskell-Cafe digest..."<br><br><br>Today's Topics:<br><br>   1. RE: Injecting Haskell into C (Simon Peyton-Jones)<br>   2. Re: Haskell board game (Ryan Ingram)<br>   3. Re: Am I doing it right? (Achim Schneider)<br>   4. Re: if - then - else layout (Jules Bean)<br>   5. Re: if - then - else layout (Achim Schneider)<br>  
 6. Re: Distributing Haskell binaries as OSX App Bundles<br>      (Christian Maeder)<br>   7. Re: if - then - else layout (Achim Schneider)<br>   8. Re: if - then - else layout (Achim Schneider)<br>   9. announcing darcs 2.1.0pre2 (Eric Kow)<br>  10. Re: pure Haskell database (jean-christophe mincke)<br>  11. Re: pure Haskell database (Achim Schneider)<br>  12. Re: pure Haskell database (Marc Weber)<br>  13. Re[2]: [Haskell-cafe] pure Haskell database (Bulat Ziganshin)<br>  14. Re: Google Android (Adam Langley)<br>  15. Re: Google Android (Maarten Hazewinkel)<br>  16. Where is OpenGL loadMatrix ? (minh thu)<br>  17. Re: Where is OpenGL loadMatrix ? ( Krzysztof Skrz?tnicki )<br>  18. Re: Where is OpenGL loadMatrix ? (Achim Schneider)<br>  19. Re: Re: Where is OpenGL loadMatrix ? (minh thu)<br>  20. StateWriter: a monad-writing exercise (Anthony LODI)<br>  21. Re: StateWriter: a monad-writing exercise (Henning Thielemann)<br>  22. Re:
 Re: Where is OpenGL loadMatrix ? (Bit Connor)<br>  23. Re: Re: Where is OpenGL loadMatrix ? (minh thu)<br>  24. Re: Where is OpenGL loadMatrix ? (Achim Schneider)<br>  25. Re: pure Haskell database (Manlio Perillo)<br>  26. Microsoft's Craig Mundie outlines the future of    computing<br>      (Lihn, Steve)<br>  27. GHC 6.10, OS X, Fink and CPPFLAGS (Svein Ove Aas)<br>  28. Re: Climbing up the shootout... (Ketil Malde)<br>  29. Problem with existential quantification (Eric)<br><br><br>----------------------------------------------------------------------<br><br>Message: 1<br>Date: Thu, 25 Sep 2008 08:32:44 +0100<br>From: Simon Peyton-Jones &lt;<a ymailto="mailto:simonpj@microsoft.com" href="mailto:simonpj@microsoft.com">simonpj@microsoft.com</a>><br>Subject: RE: [Haskell-cafe] Injecting Haskell into C<br>To: Anatoly Yakovenko &lt;<a ymailto="mailto:aeyakovenko@gmail.com" href="mailto:aeyakovenko@gmail.com">aeyakovenko@gmail.com</a>>,   
 "<a ymailto="mailto:roma@ro-che.info" href="mailto:roma@ro-che.info">roma@ro-che.info</a>"<br>    &lt;<a ymailto="mailto:roma@ro-che.info" href="mailto:roma@ro-che.info">roma@ro-che.info</a>><br>Cc: haskell &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID:<br>    &lt;<a ymailto="mailto:638ABD0A29C8884A91BC5FB5C349B1C32D766E2F96@EA-EXMSG-C334.europe.corp.microsoft.com" href="mailto:638ABD0A29C8884A91BC5FB5C349B1C32D766E2F96@EA-EXMSG-C334.europe.corp.microsoft.com">638ABD0A29C8884A91BC5FB5C349B1C32D766E2F96@EA-EXMSG-C334.europe.corp.microsoft.com</a>><br>    <br>Content-Type: text/plain; charset="us-ascii"<br><br>Anatoly<br><br>I have not been following the details, but would you consider writing up your example on the GHC user guide Wiki?<br>        <a href="http://haskell.org/haskellwiki/GHC/Using_the_FFI"
 target="_blank">http://haskell.org/haskellwiki/GHC/Using_the_FFI</a><br><br>It's a very good way to share your experience with others.<br><br>Simon<br><br>| -----Original Message-----<br>| From: <a ymailto="mailto:haskell-cafe-bounces@haskell.org" href="mailto:haskell-cafe-bounces@haskell.org">haskell-cafe-bounces@haskell.org</a> [mailto:haskell-cafe-<br>| <a ymailto="mailto:bounces@haskell.org" href="mailto:bounces@haskell.org">bounces@haskell.org</a>] On Behalf Of Anatoly Yakovenko<br>| Sent: 24 September 2008 22:42<br>| To: <a ymailto="mailto:roma@ro-che.info" href="mailto:roma@ro-che.info">roma@ro-che.info</a><br>| Cc: haskell<br>| Subject: Re: [Haskell-cafe] Injecting Haskell into C<br>|<br>| you'll find this example really helpfull<br>|<br>|<br>| ---------- Forwarded message ----------<br>| From: Claude Heiland-Allen &lt;<a ymailto="mailto:claudiusmaximus@goto10.org" href="mailto:claudiusmaximus@goto10.org">claudiusmaximus@goto10.org</a>><br>|
 Date: 2008/6/5<br>| Subject: Re: [Haskell-cafe] example of FFI FunPtr<br>| To: "Galchin, Vasili" &lt;<a ymailto="mailto:vigalchin@gmail.com" href="mailto:vigalchin@gmail.com">vigalchin@gmail.com</a>><br>| Cc: haskell &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>|<br>|<br>| Galchin, Vasili wrote:<br>| ><br>| > Hello,<br>| ><br>| >       I want to model a Haskell function that is a callback from C. I have<br>| > only found one example in the unix package's Semaphore.hsc, which<br>| apparently<br>| > is not used. I want to be able to marshall a Haskell function that is a<br>| > first class citizen residing in a Haskell data type and pass to a C<br>| function<br>| > via FFI. Are there examples of this?<br>|<br>| Attached is a simple example.<br>|<br>| The main thing to note is 'foreign import ccall "wrapper"' which gives<br>| you a factory for turning Haskell functions into
 foreign function<br>| pointers.<br>|<br>| More information:<br>|<br>| <a href="http://www.cse.unsw.edu.au/~chak/haskell/ffi/" target="_blank">http://www.cse.unsw.edu.au/~chak/haskell/ffi/</a><br>|<br>|<br>| Claude<br>| --<br>| <a href="http://claudiusmaximus.goto10.org" target="_blank">http://claudiusmaximus.goto10.org</a><br>|<br>|<br>| CallBacker: CallBacker.hs callerback.c callerback.h<br>|        ghc -O2 -Wall -fffi -o CallBacker CallBacker.hs callerback.c<br>|<br>| _______________________________________________<br>| Haskell-Cafe mailing list<br>| <a ymailto="mailto:Haskell-Cafe@haskell.org" href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>| <a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br><br><br>------------------------------<br><br>Message: 2<br>Date: Thu, 25 Sep 2008 01:09:02 -0700<br>From: "Ryan Ingram" &lt;<a
 ymailto="mailto:ryani.spam@gmail.com" href="mailto:ryani.spam@gmail.com">ryani.spam@gmail.com</a>><br>Subject: Re: [Haskell-cafe] Haskell board game<br>To: "Rafael C. de Almeida" &lt;<a ymailto="mailto:almeidaraf@gmail.com" href="mailto:almeidaraf@gmail.com">almeidaraf@gmail.com</a>><br>Cc: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:<br>    &lt;<a ymailto="mailto:2f9b2d30809250109g3f0a2359s31a003c515549875@mail.gmail.com" href="mailto:2f9b2d30809250109g3f0a2359s31a003c515549875@mail.gmail.com">2f9b2d30809250109g3f0a2359s31a003c515549875@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>Bertram has put together a peg solitaire game using gtk2hs with Prompt<br>for control:<br>    <a href="http://int-e.home.tlink.de/haskell/solitaire.tar.gz" target="_blank">http://int-e.home.tlink.de/haskell/solitaire.tar.gz</a><br><br>It's a good read and
 probably a good starting point for other board games.<br><br>  -- ryan<br><br>On Wed, Sep 24, 2008 at 7:04 PM, Rafael C. de Almeida<br>&lt;<a ymailto="mailto:almeidaraf@gmail.com" href="mailto:almeidaraf@gmail.com">almeidaraf@gmail.com</a>> wrote:<br>> Hello,<br>><br>> I'm interested in doing a simple board game on haskell. For that I want<br>> to be able to draw stuff like the possible player movements and I want<br>> to be able to display very simple animations. I want to know what<br>> graphical interface library you suggest to me.<br>><br>> I have almost no prior experience with graphical interfaces of any kind,<br>> so I rather start with something easy and straightforward. I have no<br>> need for great performance or anything like that. I'd like if it runs on<br>> windows with much trouble, that is, it'll be easy to package it for<br>> windows without requiring the user to install anything besides my game.<br>><br>> My first thought was to use
 GTK's gtkTable, but I'm unsure how easy it<br>> is to make it work on windows. Beside that, I'm not sure it would be the<br>>  easiest API for me to use.<br>><br>> []'s<br>> Rafael<br>> _______________________________________________<br>> Haskell-Cafe mailing list<br>> <a ymailto="mailto:Haskell-Cafe@haskell.org" href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>> <a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br>><br><br><br>------------------------------<br><br>Message: 3<br>Date: Thu, 25 Sep 2008 10:41:38 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re: Am I doing it right?<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:
 &lt;20080925104138.02079514@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>Daniel Fischer &lt;<a ymailto="mailto:daniel.is.fischer@web.de" href="mailto:daniel.is.fischer@web.de">daniel.is.fischer@web.de</a>> wrote:<br>> The fast searching function on ByteStrings has already been written<br>> for you :)<br>><br>That's in ghc 6.8.3, which is not in gentoo but only in the haskell<br>overlay, which means that all blame goes to the gentoo maintainers for<br>being utterly out of date. <br><br>The KMP import works like a charm.<br><br>findSubstring is only defined for strict bytestrings... try<br>running those benchmarks again, this time on data bigger than your ram.<br>Not to mention that it's deprecated.<br><br>The really interesting topic is hacking Parsec to use KMP search on<br>"manyTill anyChar (try string match), or rather any recursive try<br>involving combinators that can calculate the position for the next<br>candidate match as a side
 effect.<br><br>PS: Thank you for not pointing out that my original code crashes on<br>B.tail B.empty in some cases, or even just that it can't replace<br>overlapping matches at all.<br><br>-- <br>(c) this sig last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 4<br>Date: Thu, 25 Sep 2008 09:45:12 +0100<br>From: Jules Bean &lt;<a ymailto="mailto:jules@jellybean.co.uk" href="mailto:jules@jellybean.co.uk">jules@jellybean.co.uk</a>><br>Subject: Re: [Haskell-cafe] if - then - else layout<br>To: leledumbo &lt;<a ymailto="mailto:leledumbo_cool@yahoo.co.id" href="mailto:leledumbo_cool@yahoo.co.id">leledumbo_cool@yahoo.co.id</a>><br>Cc: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:
 &lt;<a ymailto="mailto:48DB4F98.9000804@jellybean.co.uk" href="mailto:48DB4F98.9000804@jellybean.co.uk">48DB4F98.9000804@jellybean.co.uk</a>><br>Content-Type: text/plain; charset=ISO-8859-1; format=flowed<br><br>leledumbo wrote:<br>> consider this partial program:<br>> if n>5 then<br>>   putStrLn "big"<br>> else<br>>   putStrLn "small"<br>> <br>> this works fine in hugs, but in ghc I must change it to:<br>> if n>5<br>>   then<br>>     putStrLn "big"<br>>   else<br>>     putStrLn "small"<br><br>Actually both of those are valid expressions.<br><br>And they both work in hugs and ghc.<br><br>The question I imagine you're asking involves layout mode:<br><br>do<br>   if n>5 then<br>     putStrLn "big"<br>   else<br>     putStrLn "small"<br><br>this is shorthand for<br><br>do { if n > 5 then putStrLn "big" ; else putStrLn "small" }<br><br>which is a syntax error. A statement in a do block cannot begin with the <br>keyword "else".<br><br>If you
 indent the else a bit further than it counts and a continuation <br>of the enclosing expression (beginning with if) so it desugars to<br><br>do { if n > 5 then putStrLn "big" else putStrLn "small" }<br><br>which is fine.<br><br>Haskell' is apparently going to include a hack to permit this case. I <br>think that's a poor decision, because including a hack to the layout <br>rule makes it harder to understand and explain the layout rule.<br><br>Jules<br><br><br>------------------------------<br><br>Message: 5<br>Date: Thu, 25 Sep 2008 10:48:21 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re: if - then - else layout<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;20080925104821.09da2a93@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>"Brandon S. Allbery
 KF8NH" &lt;<a ymailto="mailto:allbery@ece.cmu.edu" href="mailto:allbery@ece.cmu.edu">allbery@ece.cmu.edu</a>> wrote:<br><br>> I think Hugs is violating the Haskell98 layout rules.<br>><br>One could argue that GHC should, too.<br><br>-- <br>(c) this sig last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 6<br>Date: Thu, 25 Sep 2008 11:04:00 +0200<br>From: Christian Maeder &lt;<a ymailto="mailto:Christian.Maeder@dfki.de" href="mailto:Christian.Maeder@dfki.de">Christian.Maeder@dfki.de</a>><br>Subject: [Haskell-cafe] Re: Distributing Haskell binaries as OSX App<br>    Bundles<br>To: Stephen &lt;<a ymailto="mailto:analytic@gmail.com" href="mailto:analytic@gmail.com">analytic@gmail.com</a>><br>Cc: <a ymailto="mailto:Haskell-Cafe@haskell.org"
 href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>Message-ID: &lt;<a ymailto="mailto:48DB5400.4060804@dfki.de" href="mailto:48DB5400.4060804@dfki.de">48DB5400.4060804@dfki.de</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>Stephen wrote:<br>> I wrote a command-line program recently for a friend in haskell. <br>> However, he's far away and not particularly computer literate.  I sent<br>> him the raw binaries, but they came up with errors about not being able<br>> to find libgmp stuff.  So then I thought I should probably be able to<br><br>I usually link in libgmp.a statically. This happens automatically if<br>libgmp.a resides in ghc's libdir (just copy it)<br><br>Cheers Christian<br><br><br>------------------------------<br><br>Message: 7<br>Date: Thu, 25 Sep 2008 11:12:26 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re:
 if - then - else layout<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;20080925111226.67482196@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>Jules Bean &lt;<a ymailto="mailto:jules@jellybean.co.uk" href="mailto:jules@jellybean.co.uk">jules@jellybean.co.uk</a>> wrote:<br><br>> do<br>>    if n>5 then<br>>      putStrLn "big"<br>>    else<br>>      putStrLn "small"<br>> <br>> this is shorthand for<br>> <br>> do { if n > 5 then putStrLn "big" ; else putStrLn "small" }<br>> <br>> which is a syntax error. A statement in a do block cannot begin with<br>> the keyword "else".<br>> <br>> Haskell' is apparently going to include a hack to permit this case. I <br>> think that's a poor decision, because including a hack to the layout <br>> rule makes it harder to understand and explain the layout rule.<br>> <br>There's no need to hack the layout rule,
 you're even giving pointers to<br>the solution. Something like this:<br><br>if p = do<br>    (_, c, a) &lt;- get<br>    put (b, c, a)<br>    mzero<br><br>then c = do<br>    (b, _, a) &lt;- get<br>    put (b, c, a)<br>    mzero<br><br>else a = do<br>    (b, c, _) &lt;- get<br>    put (b, c, a)<br>    mzero<br><br>end = do<br>    (b, c, a) &lt;- get<br>    return if p then a else c<br><br>Advantages are obvious: Order doesn't really matter anymore, as in<br><br>then "get away"<br>else "or else"<br>if i tell you to<br>end<br><br>Furthermore, this scheme supports logical comments, a rare kind of<br>control structure enabling mindboggingly diverse rapid prototyping<br>options:<br><br>if i knew what i want to do<br>if i knew how to do it<br>then i'd have written the next line much earlier<br>if i wrote this line<br>then i don't need to remove the other lines<br>else where in other languages i'd have to do that<br>end<br><br>--
 <br>(c) this sig last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 8<br>Date: Thu, 25 Sep 2008 11:20:58 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re: if - then - else layout<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;20080925112058.46e0c095@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>> wrote:<br><br>> if i knew how to do it<br><br>Sorry, apparent mistake, besides confusing b (bool) with p (predicate):<br><br>if p _ c = do<br>    (_, _,
 a) &lt;- get<br>    put (p, c, a)<br>    mzero<br><br>-- <br>(c) this sig last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 9<br>Date: Thu, 25 Sep 2008 10:32:27 +0100<br>From: Eric Kow &lt;<a ymailto="mailto:kowey@darcs.net" href="mailto:kowey@darcs.net">kowey@darcs.net</a>><br>Subject: [Haskell-cafe] announcing darcs 2.1.0pre2<br>To: <a ymailto="mailto:darcs-users@darcs.net" href="mailto:darcs-users@darcs.net">darcs-users@darcs.net</a><br>Cc: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;<a ymailto="mailto:20080925093227.GG301@Macintosh.local" href="mailto:20080925093227.GG301@Macintosh.local">20080925093227.GG301@Macintosh.local</a>><br>Content-Type:
 text/plain; charset="utf-8"<br><br>Hi everybody,<br><br>The second pre-release of darcs 2.1 (formerly known as 2.0.3) is now<br>available at <a href="http://darcs.net/darcs-2.1.0pre2.tar.gz" target="_blank">http://darcs.net/darcs-2.1.0pre2.tar.gz</a><br><br>We have increased the version number since the last pre-release because<br>we are adopting an important new behaviour:<br><br>  The darcs initialize command now creates darcs-2 format<br>  repositories by default<br><br>This will help new repositories to benefit from the improved handling of<br>duplicate patches and to avoid the exponential time conflicts problem.<br><br>Upcoming release schedule<br>-------------------------<br>2008-10-03: darcs 2.1.0pre3<br>2008-10-10: darcs 2.1.0<br><br>Work remaining<br>--------------<br>* <a href="http://bugs.darcs.net/issue971" target="_blank">http://bugs.darcs.net/issue971</a> (Petr Ročkai)<br>  When using hashed or repositories, allow darcs check to deal
 with filenames<br>  that differ only in case when run on a case-insensitive filesystem.  Petr<br>  has done 90% of the work for this -- he has implemented this for darcs<br>  repair -- so this shall largely be a question of refactoring.<br><br>* <a href="http://bugs.darcs.net/issue1003" target="_blank">http://bugs.darcs.net/issue1003</a><br>  Allow darcs-transfer mode to deal with a specific set of missing files<br>  (namely _darcs/format) so that users can benefit from ssh connection<br>  sharing even if the remote end uses an old-fashioned repository.  In<br>  the meantime, a simple workaround is to touch the _darcs/format file in<br>  the remote repoistory<br>  <br>* <a href="http://bugs.darcs.net/issue1078" target="_blank">http://bugs.darcs.net/issue1078</a><br>  Fix a corner case in paths handling that makes darcs overly<br>  cautious if the repository is a symbolic link<br><br>* <a href="http://bugs.darcs.net/issue1026"
 target="_blank">http://bugs.darcs.net/issue1026</a><br>  Improve the error messages for 'bug in get_extra' errors, which can<br>  happen if darcs is fooled into thinking that two patches are the same.<br><br>Changes since the last pre-release<br>----------------------------------<br>* User Experience: Do not allow users to add files to a darcs repository if<br>  their filenames would be considered invalid under Windows. This can be<br>  overridden with the --reserved-ok flag (issue53, Eric Kow)<br><br>* Bug Fix: Do not leave behind a half-gotten directory if darcs get fails<br>  (issue1041, Vlad Dogaru, David Roundy)<br><br>* User Experience: notice when you are trying to pull from a seemingly<br>  unrelated repository, that is one with a sufficiently different history.<br>  This can be overridden with the --allow-unrelated-repos flag (Dmitry<br>  Kurochkin, David Roundy)<br><br>* Bug Fix: Fix hang after a user input error (for example, EOF)
 (Judah<br>  Jacobson)<br><br>* Quality Assurance: Improvements to documentation and online help (Simon<br>  Michael)<br><br>-- <br>Eric Kow &lt;<a href="http://www.nltg.brighton.ac.uk/home/Eric.Kow" target="_blank">http://www.nltg.brighton.ac.uk/home/Eric.Kow</a>><br>PGP Key ID: 08AC04F9<br>-------------- next part --------------<br>A non-text attachment was scrubbed...<br>Name: not available<br>Type: application/pgp-signature<br>Size: 194 bytes<br>Desc: not available<br>Url : <a href="http://www.haskell.org/pipermail/haskell-cafe/attachments/20080925/ec45f502/attachment-0001.bin" target="_blank">http://www.haskell.org/pipermail/haskell-cafe/attachments/20080925/ec45f502/attachment-0001.bin</a><br><br>------------------------------<br><br>Message: 10<br>Date: Thu, 25 Sep 2008 11:52:26 +0200<br>From: "jean-christophe mincke" &lt;<a ymailto="mailto:jeanchristophe.mincke@gmail.com"
 href="mailto:jeanchristophe.mincke@gmail.com">jeanchristophe.mincke@gmail.com</a>><br>Subject: Re: [Haskell-cafe] pure Haskell database<br>To: "Marc Weber" &lt;<a ymailto="mailto:marco-oweber@gmx.de" href="mailto:marco-oweber@gmx.de">marco-oweber@gmx.de</a>>, <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:<br>    &lt;<a ymailto="mailto:c0727ea70809250252gb1ea978j661df85f79a529b1@mail.gmail.com" href="mailto:c0727ea70809250252gb1ea978j661df85f79a529b1@mail.gmail.com">c0727ea70809250252gb1ea978j661df85f79a529b1@mail.gmail.com</a>><br>Content-Type: text/plain; charset="iso-8859-1"<br><br>Marc<br><br>What is this strange syntax<br><br>columns = [ ("trackId", conT *''Int* )<br><br>It looks like a not ended string literal unless I still have sth to learn<br>about Haskell.<br><br>Thank you<br><br>J-C<br><br><br><br>On Thu, Sep 25, 2008 at 12:03 AM, Marc Weber &lt;<a
 ymailto="mailto:marco-oweber@gmx.de" href="mailto:marco-oweber@gmx.de">marco-oweber@gmx.de</a>> wrote:<br><br>> On Wed, Sep 24, 2008 at 11:17:01PM +0200, Manlio Perillo wrote:<br>> >  Hi.<br>> ><br>> >  I need a simple, concurrent safe, database, written in Haskell.<br>> >  A database with the interface of Data.Map would be great, since what I<br>> need<br>> >  to to is atomically increment some integer values, and I would like to<br>> avoid<br>> >  to use SQLite.<br>><br>> I've tried writing at least part of that. But it's still higly<br>> experimental and uses template haskell.<br>> It looks like this:<br>> from that some datastructures are defined which look like<br>> tables used in traditional RDBMS such as SQLite..<br>> However if you don't want to use many "tables" you may be a lot faster<br>> writing down what you need yourself. My lib automacially generates code<br>> for inserting / deleting tuples into multi indexes such as (Map Int
 (Map<br>> Int PrimIdx)).<br>><br>> $(let cds = defaultTable {<br>>                tblName = "cds"<br>>                , columns = [ ("cdId", conT ''Int) , ("title", conT ''Int) ]<br>>                , primary = PrimaryUniq [ "cdId" ] [| 0 |]<br>>                , indexes = [ Index "title" [] ]<br>>                , tblStates = [ ( "nextCdId", [t| Int |], [| 0 |] ) ]<br>>            }<br>><br>>      tracks = let<br>>             a="a"<br>>             -- updateNumRows n = [| \n -> cdUpdateByPK (\r -> r {<br>> num_tracks = (num_tracks r) + $(n) } ) |]<br>>             in defaultTable {<br>>             tblName = "tracks"<br>>             , columns = [ ("trackId", conT ''Int )<br>>                       , ("name", conT ''String)<br>>                       , ("cd", conT ''Int) -- foreign key<br>>                       ]<br>>             ,
 primary = PrimaryUniq [ "cd", "trackId" ] [| 0 |]<br>>             , indexes = [ Index "cd" [ IndexUnique "trackId" ] ] --the id<br>> is uniq foreach cd<br>>             -- checks = [ foreignConstraint "cd" "cds" "id" ]<br>>             -- triggers =  [ InsertUpdate  (Just ["cd"]) [| cdUpdateByPK (<br>> updateNum_tracks (+1) ) . pk |]<br>>                           -- DeleteUpdate  (Just ["cd"]) [| cdUpdateByPK (<br>> updateNum_tracks (-1) ) . pk |]<br>>                           -- ]<br>>                 }<br>>      db = defaultDB {<br>>              dbName = "my"<br>>            , tables = [ cds, tracks]<br>>            , statistics = True<br>>            }<br>>  in createDB db)<br>><br>><br>> If you're interested drop me a mail.<br>><br>> Marc<br>> _______________________________________________<br>> Haskell-Cafe mailing list<br>> <a
 ymailto="mailto:Haskell-Cafe@haskell.org" href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>> <a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br>><br>-------------- next part --------------<br>An HTML attachment was scrubbed...<br>URL: <a href="http://www.haskell.org/pipermail/haskell-cafe/attachments/20080925/86f028ab/attachment-0001.htm" target="_blank">http://www.haskell.org/pipermail/haskell-cafe/attachments/20080925/86f028ab/attachment-0001.htm</a><br><br>------------------------------<br><br>Message: 11<br>Date: Thu, 25 Sep 2008 12:08:28 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re: pure Haskell database<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:
 &lt;20080925120828.09fec80f@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>"jean-christophe mincke" &lt;<a ymailto="mailto:jeanchristophe.mincke@gmail.com" href="mailto:jeanchristophe.mincke@gmail.com">jeanchristophe.mincke@gmail.com</a>> wrote:<br><br>> What is this strange syntax<br>> <br>> columns = [ ("trackId", conT *''Int* )<br>> <br>> It looks like a not ended string literal unless I still have sth to<br>> learn about Haskell.<br>> <br>' isn't special in Haskell, it's idiomatic: you often see things like<br><br>foo' = bar foo<br><br>, as mathematicians and haskellers are to lazy to think of a new name<br>for foo just because they got a derived foo.<br><br>I, too, have no idea what *''Int* means. It's part of the "just use the<br>*&amp;%*$^!#!$%!^ operator" problem.<br><br>-- <br>(c) this sig last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance
 and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 12<br>Date: Thu, 25 Sep 2008 12:31:44 +0200<br>From: Marc Weber &lt;<a ymailto="mailto:marco-oweber@gmx.de" href="mailto:marco-oweber@gmx.de">marco-oweber@gmx.de</a>><br>Subject: Re: [Haskell-cafe] pure Haskell database<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;<a ymailto="mailto:20080925103144.GA18833@gmx.de" href="mailto:20080925103144.GA18833@gmx.de">20080925103144.GA18833@gmx.de</a>><br>Content-Type: text/plain; charset=utf-8<br><br>On Thu, Sep 25, 2008 at 11:52:26AM +0200, jean-christophe mincke wrote:<br>>    Marc<br>> <br>>    What is this strange syntax<br>> <br>>    columns = [ ("trackId", conT ''Int )<br><br>Hi J-C,<br><br>I'ts part of template haskell and tells ghc to use the type<br>referenced by Int. There are some getting
 started guides on haskell.org<br>By the way you can enhance readability of your messages if you only keep<br>that part of the message you're refering to.<br><br>Sincerly<br>Marc Weber<br><br><br>------------------------------<br><br>Message: 13<br>Date: Thu, 25 Sep 2008 14:48:12 +0400<br>From: Bulat Ziganshin &lt;<a ymailto="mailto:bulat.ziganshin@gmail.com" href="mailto:bulat.ziganshin@gmail.com">bulat.ziganshin@gmail.com</a>><br>Subject: Re[2]: [Haskell-cafe] pure Haskell database<br>To: "jean-christophe mincke" &lt;<a ymailto="mailto:jeanchristophe.mincke@gmail.com" href="mailto:jeanchristophe.mincke@gmail.com">jeanchristophe.mincke@gmail.com</a>><br>Cc: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;<a ymailto="mailto:988210512.20080925144812@gmail.com" href="mailto:988210512.20080925144812@gmail.com">988210512.20080925144812@gmail.com</a>><br>Content-Type:
 text/plain; charset=us-ascii<br><br>Hello jean-christophe,<br><br>Thursday, September 25, 2008, 1:52:26 PM, you wrote:<br><br>>  columns = [ ("trackId", conT ''Int )<br><br>> It looks like a not ended string literal unless I still have sth to learn about Haskell.<br><br>it's TemplateHaskell, look for Reification in <a href="http://www.haskell.org/bz/thdoc.htm" target="_blank">http://www.haskell.org/bz/thdoc.htm</a><br><br><br>-- <br>Best regards,<br> Bulat                            mailto:<a ymailto="mailto:Bulat.Ziganshin@gmail.com" href="mailto:Bulat.Ziganshin@gmail.com">Bulat.Ziganshin@gmail.com</a><br><br><br><br>------------------------------<br><br>Message: 14<br>Date: Thu, 25 Sep 2008 04:33:09 -0700<br>From: "Adam Langley" &lt;<a ymailto="mailto:agl@imperialviolet.org" href="mailto:agl@imperialviolet.org">agl@imperialviolet.org</a>><br>Subject: Re: [Haskell-cafe] Google Android<br>To: "Galchin, Vasili" &lt;<a
 ymailto="mailto:vigalchin@gmail.com" href="mailto:vigalchin@gmail.com">vigalchin@gmail.com</a>><br>Cc: "<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>" &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID:<br>    &lt;<a ymailto="mailto:396556a20809250433n75d817bfr30847a0fe6334ff@mail.gmail.com" href="mailto:396556a20809250433n75d817bfr30847a0fe6334ff@mail.gmail.com">396556a20809250433n75d817bfr30847a0fe6334ff@mail.gmail.com</a>><br>Content-Type: text/plain; charset=UTF-8<br><br>2008/9/24 Galchin, Vasili &lt;<a ymailto="mailto:vigalchin@gmail.com" href="mailto:vigalchin@gmail.com">vigalchin@gmail.com</a>>:<br>>     Do there currently (or in the works) exist FFI bindings for Google's<br>> Android API?<br><br>The Android API is obviously a Java API, additionally Android will<br>only execute DEX bytecode
 programs, so you would first need a way to<br>compile Haskell to Java, Java bytecode or DEX directly. A Google<br>search for "haskell java" turns up at least one good candidate[1], but<br>if you manage to get that working well, binding the APIs is a rather<br>trivial task ;)<br><br><br>[1] <a href="http://www.cse.unsw.edu.au/~pls/thesis-topics/ghcjava.html" target="_blank">http://www.cse.unsw.edu.au/~pls/thesis-topics/ghcjava.html</a><br><br>AGL<br><br>-- <br>Adam Langley <a ymailto="mailto:agl@imperialviolet.org" href="mailto:agl@imperialviolet.org">agl@imperialviolet.org</a> <a href="http://www.imperialviolet.org" target="_blank">http://www.imperialviolet.org</a><br><br><br>------------------------------<br><br>Message: 15<br>Date: Thu, 25 Sep 2008 13:46:36 +0200<br>From: Maarten Hazewinkel &lt;<a ymailto="mailto:maarten.hazewinkel@gmail.com" href="mailto:maarten.hazewinkel@gmail.com">maarten.hazewinkel@gmail.com</a>><br>Subject: Re: [Haskell-cafe]
 Google Android<br>To: Adam Langley &lt;<a ymailto="mailto:agl@imperialviolet.org" href="mailto:agl@imperialviolet.org">agl@imperialviolet.org</a>><br>Cc: "Galchin, Vasili" &lt;<a ymailto="mailto:vigalchin@gmail.com" href="mailto:vigalchin@gmail.com">vigalchin@gmail.com</a>>,<br>    "<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>" &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID: &lt;<a ymailto="mailto:3E3F4C9A-18F7-4C39-8701-839107B490CD@mac.com" href="mailto:3E3F4C9A-18F7-4C39-8701-839107B490CD@mac.com">3E3F4C9A-18F7-4C39-8701-839107B490CD@mac.com</a>><br>Content-Type: text/plain; charset=US-ASCII; format=flowed<br><br>On 25 Sep 2008, at 13:33, Adam Langley wrote:<br><br>> A Google<br>> search for "haskell java" turns up at least one good candidate[1], but<br>> if you manage to get that working well,
 binding the APIs is a rather<br>> trivial task ;)<br>><br>> [1] <a href="http://www.cse.unsw.edu.au/~pls/thesis-topics/ghcjava.html" target="_blank">http://www.cse.unsw.edu.au/~pls/thesis-topics/ghcjava.html</a><br><br>That's actually just a thesis proposal, not actual work done.<br>Try this for something closer to realization:<br><br><a href="http://www.cs.rit.edu/~bja8464/lambdavm/" target="_blank">http://www.cs.rit.edu/~bja8464/lambdavm/</a><br><br><br>Regards,<br><br>Maarten<br><br><br>------------------------------<br><br>Message: 16<br>Date: Thu, 25 Sep 2008 15:39:22 +0200<br>From: "minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>><br>Subject: [Haskell-cafe] Where is OpenGL loadMatrix ?<br>To: "Haskell-cafe Cafe" &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID:<br>    &lt;<a
 ymailto="mailto:40a414c20809250639s2da31e6fv24c797ca3e328381@mail.gmail.com" href="mailto:40a414c20809250639s2da31e6fv24c797ca3e328381@mail.gmail.com">40a414c20809250639s2da31e6fv24c797ca3e328381@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>Hi,<br><br>I can't find the loadMatrix function in<br><a href="http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html" target="_blank">http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html</a><br><br>Should I use loadIdentity then multMatrix instead ?<br><br>Thank you,<br>Thu<br><br><br>------------------------------<br><br>Message: 17<br>Date: Thu, 25 Sep 2008 15:45:21 +0200<br>From: " Krzysztof Skrz?tnicki " &lt;<a ymailto="mailto:gtener@gmail.com" href="mailto:gtener@gmail.com">gtener@gmail.com</a>><br>Subject: Re: [Haskell-cafe] Where is OpenGL loadMatrix ?<br>To: "minh
 thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>><br>Cc: Haskell-cafe Cafe &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID:<br>    &lt;<a ymailto="mailto:220e47b40809250645o51a3ab47mbde6e0b7c90e28e0@mail.gmail.com" href="mailto:220e47b40809250645o51a3ab47mbde6e0b7c90e28e0@mail.gmail.com">220e47b40809250645o51a3ab47mbde6e0b7c90e28e0@mail.gmail.com</a>><br>Content-Type: text/plain; charset=UTF-8<br><br>On Thu, Sep 25, 2008 at 15:39, minh thu &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>> wrote:<br>><br>> Hi,<br>><br>> I can't find the loadMatrix function in<br>> <a href="http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html"
 target="_blank">http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html</a><br>><br>> Should I use loadIdentity then multMatrix instead ?<br>><br>> Thank you,<br>> Thu<br>> _______________________________________________<br>> Haskell-Cafe mailing list<br>> <a ymailto="mailto:Haskell-Cafe@haskell.org" href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>> <a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br><br>>From what I can see in the source, loadMatrix is method of class<br>MatrixComponent [1]:<br><br>instance MatrixComponent GLfloat_ where<br>   getMatrix = getFloatv<br>   loadMatrix = glLoadMatrixf<br>   loadTransposeMatrix = glLoadTransposeMatrixfARB<br>   multMatrix_ = glMultMatrixf<br>   multTransposeMatrix = glMultTransposeMatrixfARB<br>   rotate a (Vector3 x y z) = glRotatef a x
 y z<br>   translate (Vector3 x y z) = glTranslatef x y z<br>   scale = glScalef<br><br>However, for some reason it is not exported:<br><br>   MatrixOrder(..), MatrixComponent(rotate,translate,scale), Matrix(..),<br><br>Best regards<br><br>Christopher Skrzętnicki<br><br>[1]: <a href="http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/src/Graphics-Rendering-OpenGL-GL-CoordTrans.html#MatrixComponent" target="_blank">http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/src/Graphics-Rendering-OpenGL-GL-CoordTrans.html#MatrixComponent</a><br><br>------------------------------<br><br>Message: 18<br>Date: Thu, 25 Sep 2008 15:59:35 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re: Where is OpenGL loadMatrix ?<br>To: <a ymailto="mailto:haskell-cafe@haskell.org"
 href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;20080925155935.7ea6f1cc@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>"minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>> wrote:<br><br>> I can't find the loadMatrix function in<br>> <a href="http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html" target="_blank">http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html</a><br>> <br>> Should I use loadIdentity then multMatrix instead ?<br>> <br>You're supposed to use withMatrix and regard OpenGL not as an<br>imperative language, but as a markup language coincidentally using<br>"do" to specify (flattened) lists. I even read about some library<br>managing display lists transparently for you, but I can't recall where.<br><br>-- <br>(c) this sig
 last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 19<br>Date: Thu, 25 Sep 2008 16:12:31 +0200<br>From: "minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>><br>Subject: Re: [Haskell-cafe] Re: Where is OpenGL loadMatrix ?<br>To: "Achim Schneider" &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Cc: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:<br>    &lt;<a ymailto="mailto:40a414c20809250712m2d4f9effy35506a0934dfeaf7@mail.gmail.com"
 href="mailto:40a414c20809250712m2d4f9effy35506a0934dfeaf7@mail.gmail.com">40a414c20809250712m2d4f9effy35506a0934dfeaf7@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>2008/9/25 Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>>:<br>> "minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>> wrote:<br>><br>>> I can't find the loadMatrix function in<br>>> <a href="http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html" target="_blank">http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html</a><br>>><br>>> Should I use loadIdentity then multMatrix instead ?<br>>><br>> You're supposed to use withMatrix and regard OpenGL not as an<br>> imperative language, but as a markup language coincidentally using<br>> "do" to specify
 (flattened) lists. I even read about some library<br>> managing display lists transparently for you, but I can't recall where.<br><br>If you're right, it's weird there are things like  loadIdentity, $=,<br>... and it is<br>even weirder to not provide loadMatrix (which can be done with<br>loadIdenity and multMatrix).<br><br>Anyway, the bindings are not that much functionnal, even with things<br>like withMatrix.<br><br>Cheers<br>Thu<br><br><br>------------------------------<br><br>Message: 20<br>Date: Thu, 25 Sep 2008 10:18:13 -0400<br>From: "Anthony LODI" &lt;<a ymailto="mailto:anthony.lodi@gmail.com" href="mailto:anthony.lodi@gmail.com">anthony.lodi@gmail.com</a>><br>Subject: [Haskell-cafe] StateWriter: a monad-writing exercise<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:<br>    &lt;<a ymailto="mailto:d58ec4e0809250718xfb315aevc567750d7f5c99dc@mail.gmail.com"
 href="mailto:d58ec4e0809250718xfb315aevc567750d7f5c99dc@mail.gmail.com">d58ec4e0809250718xfb315aevc567750d7f5c99dc@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>Hello haskell-cafe,<br><br>In my application I have a complex state threaded through long<br>computation chains, and I need a way to log all state changes (so that<br>the evolving state can be animated/replayed somewhere else).<br>Initially I tried combining State and Writer monads but this allows<br>for the possibility to change the state, and forget to write a log<br>entry, etc.<br><br>So I decided to write a separate monad, StateWriter l s, that takes a<br>state-modifying function, l->s->s (l is an ADT for all the allowable<br>state transitions), an initial state s, and only allows s to change by<br>appending 'l' log entries inside the monad.  The net result is that I<br>should have read-only access to the current state inside the monad,<br>and all state
 transitions should be logged (by going through the one<br>function, the log entries serve as witnesses to all state<br>transitions).<br><br>Anyway, here's my (very rough!) first stab at the problem.  This is<br>the first time I've tried writing a monad so any comments/critiques<br>are much appreciated.<br><br>Also, about the 'StateWriter' idea in general: am I just (poorly?)<br>reimplementing something obvious?  Is it unlikely to scale well on<br>real-world problems?  Is there some way to combine the existing State<br>and Writer monads to avoid having to do this?<br><br>If there's nothing seriously wrong here, I was thinking my next step<br>would be to try changing the lists to monoids (like in the Writer<br>monad), and then to try writing a transformer version of the whole<br>thing.<br><br>Cheers,<br><br>- Anthony LODI<br><br><br>================================================================================<br><br>{-# LANGUAGE
 MultiParamTypeClasses,<br>            FunctionalDependencies,<br>            FlexibleInstances #-}<br><br>newtype StateWriter l s a = StateWriter { _runSWriter :: (l -> s -> s)<br>                                                     -> [l]<br>                                                     -> s<br>                                                     -> (a, [l], s)<br>                                       }<br><br><br>instance Monad (StateWriter l s) where<br>   return a = StateWriter $ \_ ls s -> (a, ls, s)<br><br>   (StateWriter x) >>= f = StateWriter $ \fn ls s -><br>                                let (v, ls', s') = x fn ls s<br>                                in<br>                                  _runSWriter (f v) fn ls' s'<br><br>class MonadStateWriter m l s | m -> l s where<br> put
 :: l -> m ()<br> get :: m s<br><br>instance MonadStateWriter (StateWriter l s) l s where<br> put l = StateWriter $ \fn ls s -> ((), ls ++ [l], fn l s)<br> get = StateWriter $ \fn ls s -> (s, ls, s)<br><br><br>runSWriter :: StateWriter l s a -> (l -> s -> s) -> s -> (a, [l], s)<br>runSWriter sw fn = _runSWriter sw fn []<br><br><br>--------------------------------------------------------------------------------<br><br><br>data Ops = Inc<br>        | Dec<br>          deriving (Show)<br><br>test :: StateWriter Ops Int String<br>test = do<br> put Inc<br> put Inc<br> put Inc<br> val &lt;- get<br> let op = if val == 3 then Dec else Inc<br> put op<br> return "done"<br><br>stateFn :: Ops -> Int -> Int<br>stateFn Inc s = s + 1<br>stateFn Dec s = s - 1<br><br>runtest = runSWriter test stateFn 0 -- ("done",[Inc,Inc,Inc,Dec],2)<br><br><br>------------------------------<br><br>Message: 21<br>Date: Thu, 25 Sep 2008 16:34:18 +0200 (CEST)<br>From: Henning
 Thielemann &lt;<a ymailto="mailto:lemming@henning-thielemann.de" href="mailto:lemming@henning-thielemann.de">lemming@henning-thielemann.de</a>><br>Subject: Re: [Haskell-cafe] StateWriter: a monad-writing exercise<br>To: Anthony LODI &lt;<a ymailto="mailto:anthony.lodi@gmail.com" href="mailto:anthony.lodi@gmail.com">anthony.lodi@gmail.com</a>><br>Cc: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;Pine.SOC.4.64.0809251631320.21141@verdi><br>Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed<br><br><br>On Thu, 25 Sep 2008, Anthony LODI wrote:<br><br>> Hello haskell-cafe,<br>><br>> In my application I have a complex state threaded through long<br>> computation chains, and I need a way to log all state changes (so that<br>> the evolving state can be animated/replayed somewhere else).<br>> Initially I tried combining State and Writer monads but this allows<br>> for the
 possibility to change the state, and forget to write a log<br>> entry, etc.<br><br>Instead of rewriting from scratch, you can also define<br><br>   newtype StateWriter l s a = StateWriter (StateT s (Writer l) a)<br><br>and then the monad instance is just about wrapping and unwrapping. Or you <br>use {-# LANGUAGE GeneralizedNewtypeDeriving #-} and 'deriving Monad'.<br><br><br>------------------------------<br><br>Message: 22<br>Date: Thu, 25 Sep 2008 17:39:26 +0300<br>From: "Bit Connor" &lt;<a ymailto="mailto:bit@mutantlemon.com" href="mailto:bit@mutantlemon.com">bit@mutantlemon.com</a>><br>Subject: Re: [Haskell-cafe] Re: Where is OpenGL loadMatrix ?<br>To: "minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>><br>Cc: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>>, <a ymailto="mailto:haskell-cafe@haskell.org"
 href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:<br>    &lt;<a ymailto="mailto:6205bd290809250739u4b987f7cm285624fb9d5b6601@mail.gmail.com" href="mailto:6205bd290809250739u4b987f7cm285624fb9d5b6601@mail.gmail.com">6205bd290809250739u4b987f7cm285624fb9d5b6601@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>withMatrix doesn't seem to have anything to do with glLoadMatrix.<br><br>You are right that you can do glLoadMatrix with loadIdentity and multMatrix.<br><br>To directly load a matrix, use the function "matrix" (with a Nothing<br>argument). This will internally call the loadMatrix function that<br>Krzysztof mentioned (which is correctly not exported).<br><br>Note that in addition to loading a matrix, the "matrix" function is<br>also used for retrieving the current matrix. (glGetFloatv with<br>argument GL_MODELVIEW_MATRIX and friends).<br><br>On Thu, Sep 25, 2008 at 5:12 PM, minh thu &lt;<a
 ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>> wrote:<br>> 2008/9/25 Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>>:<br>>> "minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>> wrote:<br>>><br>>>> I can't find the loadMatrix function in<br>>>> <a href="http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html" target="_blank">http://hackage.haskell.org/packages/archive/OpenGL/latest/doc/html/Graphics-Rendering-OpenGL-GL-CoordTrans.html</a><br>>>><br>>>> Should I use loadIdentity then multMatrix instead ?<br>>>><br>>> You're supposed to use withMatrix and regard OpenGL not as an<br>>> imperative language, but as a markup language coincidentally using<br>>> "do" to specify (flattened) lists. I even read about some library<br>>> managing display lists
 transparently for you, but I can't recall where.<br>><br>> If you're right, it's weird there are things like  loadIdentity, $=,<br>> ... and it is<br>> even weirder to not provide loadMatrix (which can be done with<br>> loadIdenity and multMatrix).<br>><br>> Anyway, the bindings are not that much functionnal, even with things<br>> like withMatrix.<br>><br>> Cheers<br>> Thu<br>> _______________________________________________<br>> Haskell-Cafe mailing list<br>> <a ymailto="mailto:Haskell-Cafe@haskell.org" href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br>> <a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br>><br><br><br>------------------------------<br><br>Message: 23<br>Date: Thu, 25 Sep 2008 16:48:25 +0200<br>From: "minh thu" &lt;<a ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>><br>Subject: Re:
 [Haskell-cafe] Re: Where is OpenGL loadMatrix ?<br>To: "Bit Connor" &lt;<a ymailto="mailto:bit@mutantlemon.com" href="mailto:bit@mutantlemon.com">bit@mutantlemon.com</a>><br>Cc: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>>, <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID:<br>    &lt;<a ymailto="mailto:40a414c20809250748i2ffebafal5d20edcf7dff2bfc@mail.gmail.com" href="mailto:40a414c20809250748i2ffebafal5d20edcf7dff2bfc@mail.gmail.com">40a414c20809250748i2ffebafal5d20edcf7dff2bfc@mail.gmail.com</a>><br>Content-Type: text/plain; charset=ISO-8859-1<br><br>2008/9/25 Bit Connor &lt;<a ymailto="mailto:bit@mutantlemon.com" href="mailto:bit@mutantlemon.com">bit@mutantlemon.com</a>>:<br>> withMatrix doesn't seem to have anything to do with glLoadMatrix.<br>><br>> You are right that you can do glLoadMatrix with loadIdentity
 and multMatrix.<br>><br>> To directly load a matrix, use the function "matrix" (with a Nothing<br>> argument). This will internally call the loadMatrix function that<br>> Krzysztof mentioned (which is correctly not exported).<br>><br>> Note that in addition to loading a matrix, the "matrix" function is<br>> also used for retrieving the current matrix. (glGetFloatv with<br>> argument GL_MODELVIEW_MATRIX and friends).<br><br>Ok, thank you,<br>Thu<br><br><br>------------------------------<br><br>Message: 24<br>Date: Thu, 25 Sep 2008 16:52:52 +0200<br>From: Achim Schneider &lt;<a ymailto="mailto:barsoap@web.de" href="mailto:barsoap@web.de">barsoap@web.de</a>><br>Subject: [Haskell-cafe] Re: Where is OpenGL loadMatrix ?<br>To: <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;20080925165252.5d88839b@solaris><br>Content-Type: text/plain; charset=US-ASCII<br><br>"minh thu" &lt;<a
 ymailto="mailto:noteed@gmail.com" href="mailto:noteed@gmail.com">noteed@gmail.com</a>> wrote:<br><br>> Anyway, the bindings are not that much functionnal, even with things<br>> like withMatrix.<br>><br><a href="http://thread.gmane.org/gmane.comp.lang.haskell.cafe/35444/focus=35713" target="_blank">http://thread.gmane.org/gmane.comp.lang.haskell.cafe/35444/focus=35713</a><br><br>Mind you: regarding 3d, I barely manage to code up camera movements.<br>That is, I don't use it much at all.<br><br>-- <br>(c) this sig last receiving data processing entity. Inspect headers<br>for copyright history. All rights reserved. Copying, hiring, renting,<br>performance and/or broadcasting of this signature prohibited.<br><br><br><br>------------------------------<br><br>Message: 25<br>Date: Thu, 25 Sep 2008 18:09:18 +0200<br>From: Manlio Perillo &lt;<a ymailto="mailto:manlio_perillo@libero.it"
 href="mailto:manlio_perillo@libero.it">manlio_perillo@libero.it</a>><br>Subject: Re: [Haskell-cafe] pure Haskell database<br>To: Rich Neswold &lt;<a ymailto="mailto:rich.neswold@gmail.com" href="mailto:rich.neswold@gmail.com">rich.neswold@gmail.com</a>><br>Cc: Haskell Cafe mailing list &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID: &lt;<a ymailto="mailto:48DBB7AE.9010002@libero.it" href="mailto:48DBB7AE.9010002@libero.it">48DBB7AE.9010002@libero.it</a>><br>Content-Type: text/plain; charset=UTF-8; format=flowed<br><br>Rich Neswold ha scritto:<br>> On Wed, Sep 24, 2008 at 4:17 PM, Manlio Perillo <br>> &lt;<a ymailto="mailto:manlio_perillo@libero.it" href="mailto:manlio_perillo@libero.it">manlio_perillo@libero.it</a> &lt;mailto:<a ymailto="mailto:manlio_perillo@libero.it" href="mailto:manlio_perillo@libero.it">manlio_perillo@libero.it</a>>> wrote:<br>> <br>>     I need
 a simple, concurrent safe, database, written in Haskell.<br>>     A database with the interface of Data.Map would be great, since what<br>>     I need to to is atomically increment some integer values, and I<br>>     would like to avoid to use SQLite.<br>> <br>> <br>> How about  "MVar (Map k Int)"?  or even "Map k (MVar Int)"?<br>> <br><br>Yes, it is a solution; and I can run a thread that every N seconds <br>writes the database to a file.<br><br>But this works only if the database is used by only one process.<br><br><br>Manlio Perillo<br><br><br>------------------------------<br><br>Message: 26<br>Date: Thu, 25 Sep 2008 12:14:55 -0400<br>From: "Lihn, Steve" &lt;<a ymailto="mailto:horng_twu_lihn@merck.com" href="mailto:horng_twu_lihn@merck.com">horng_twu_lihn@merck.com</a>><br>Subject: [Haskell-cafe] Microsoft's Craig Mundie outlines the future<br>    of    computing<br>To: &lt;<a ymailto="mailto:haskell-cafe@haskell.org"
 href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID:<br>    &lt;<a ymailto="mailto:6BD267D89E66B9499514F119920E583C029A2E90@usctmx1110.merck.com" href="mailto:6BD267D89E66B9499514F119920E583C029A2E90@usctmx1110.merck.com">6BD267D89E66B9499514F119920E583C029A2E90@usctmx1110.merck.com</a>><br>Content-Type: text/plain; charset="us-ascii"<br><br><br><a href="http://news.cnet.com/8301-13953_3-10050826-80.html?part=rss&amp;subj=news&amp;ta" target="_blank">http://news.cnet.com/8301-13953_3-10050826-80.html?part=rss&amp;subj=news&amp;ta</a><br>g=2547-1_3-0-5<br><br>"We have to see a paradigm change in the way we write applications." He<br>also said that software development hasn't graduated to become a formal<br>engineering discipline. "The resilience of systems is not up to the<br>task," he said. "We have to master the transition to a parallel<br>programming environment, with highly distributed, concurrent systems.<br>It's
 nascent at this point but it's required to achieve these<br>capabilities." <br><br>Sounds like Haskell will fit well in this future world.<br><br>Notice:  This e-mail message, together with any attachments, contains<br>information of Merck &amp; Co., Inc. (One Merck Drive, Whitehouse Station,<br>New Jersey, USA 08889), and/or its affiliates (which may be known<br>outside the United States as Merck Frosst, Merck Sharp &amp; Dohme or<br>MSD and in Japan, as Banyu - direct contact information for affiliates is<br>available at <a href="http://www.merck.com/contact/contacts.html" target="_blank">http://www.merck.com/contact/contacts.html</a>) that may be<br>confidential, proprietary copyrighted and/or legally privileged. It is<br>intended solely for the use of the individual or entity named on this<br>message. If you are not the intended recipient, and have received this<br>message in error, please notify us immediately by reply e-mail and<br>then delete it
 from your system.<br><br><br><br>------------------------------<br><br>Message: 27<br>Date: Thu, 25 Sep 2008 18:27:19 +0200<br>From: "Svein Ove Aas" &lt;<a ymailto="mailto:svein.ove@aas.no" href="mailto:svein.ove@aas.no">svein.ove@aas.no</a>><br>Subject: [Haskell-cafe] GHC 6.10, OS X, Fink and CPPFLAGS<br>To: "Haskell Cafe" &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID:<br>    &lt;<a ymailto="mailto:221b53ab0809250927l2caa3359pe699c7ff6c52a8d1@mail.gmail.com" href="mailto:221b53ab0809250927l2caa3359pe699c7ff6c52a8d1@mail.gmail.com">221b53ab0809250927l2caa3359pe699c7ff6c52a8d1@mail.gmail.com</a>><br>Content-Type: text/plain; charset=UTF-8<br><br>While trying to test 6.10, I ran into the issue that a number of the<br>libraries it wants are not installed by default, and are most<br>conveniently added via Fink. This includes gmp, binutils, readline,<br>etc.<br><br>/sw/
 is not in the default gcc path, of course, so the usual solution<br>is to add -I/sw/include, -L/sw/lib, etc. to it via the CPPFLAGS and<br>LDFLAGS environment variables, which are supported by most[1]<br>autoconf-based packages. The help text for ghc's configure script does<br>in fact suggest that this is the case, and it has some code meant to<br>read it; broken code, as it happens.<br><br>As it is, the script fails to propagate those variables to whatever is<br>responsible for compiling the RTS, which fails with a missing gmp.h,<br>bfd.h, and so on. All those files exist live quite happily in<br>/sw/include, and would no doubt appreciate visiting makefiles.<br><br>So my question is two-fold:<br>Is the help file wrong? Is there some other way to do it?<br>Or is this in fact a bug, and if so, will any of you volunteer to fix<br>it for me? ^_^<br><br><br>------------------------------<br><br>Message: 28<br>Date: Thu, 25 Sep 2008 18:57:05 +0200<br>From:
 Ketil Malde &lt;<a ymailto="mailto:ketil@malde.org" href="mailto:ketil@malde.org">ketil@malde.org</a>><br>Subject: Re: [Haskell-cafe] Climbing up the shootout...<br>To: "John Van Enk" &lt;<a ymailto="mailto:vanenkj@gmail.com" href="mailto:vanenkj@gmail.com">vanenkj@gmail.com</a>><br>Cc: Bulat Ziganshin &lt;<a ymailto="mailto:Bulat.Ziganshin@gmail.com" href="mailto:Bulat.Ziganshin@gmail.com">Bulat.Ziganshin@gmail.com</a>>,<br>    <a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a><br>Message-ID: &lt;<a ymailto="mailto:87skro88pq.fsf@malde.org" href="mailto:87skro88pq.fsf@malde.org">87skro88pq.fsf@malde.org</a>><br>Content-Type: text/plain; charset=us-ascii<br><br>"John Van Enk" &lt;<a ymailto="mailto:vanenkj@gmail.com" href="mailto:vanenkj@gmail.com">vanenkj@gmail.com</a>> writes:<br><br>> I'm going to have to agree with David... even if you ignore the multi-threaded<br>> projects, why
 couldn't the C programs just implement very specific version of<br>> the third party library inside their code?<br><br>Or they could just FFI to the Haskell libraries :-)<br><br>-k<br>-- <br>If I haven't seen further, it is by standing in the footprints of giants<br><br><br>------------------------------<br><br>Message: 29<br>Date: Thu, 25 Sep 2008 18:15:56 +0100<br>From: Eric &lt;<a ymailto="mailto:eeoam@ukfsn.org" href="mailto:eeoam@ukfsn.org">eeoam@ukfsn.org</a>><br>Subject: [Haskell-cafe] Problem with existential quantification<br>To: Haskell-cafe &lt;<a ymailto="mailto:haskell-cafe@haskell.org" href="mailto:haskell-cafe@haskell.org">haskell-cafe@haskell.org</a>><br>Message-ID: &lt;<a ymailto="mailto:48DBC74C.3030303@ukfsn.org" href="mailto:48DBC74C.3030303@ukfsn.org">48DBC74C.3030303@ukfsn.org</a>><br>Content-Type: text/plain; charset=ISO-8859-1; format=flowed<br><br>Dear all,<br><br>I've written a function with the following type:<br><br>build ::
 Bifunctor s => (forall b. (s a b  ->  b) -> b)  ->  Fix s a<br><br>When I try to compile I get the following error:<br><br>Illegal polymorphic or qualified type: forall b. (s a b -> b) -> b<br>In the type signature for `build':<br>  build :: (Bifunctor s) => (forall b. (s a b -> b) -> b) -> Fix s a<br><br>What's happening?<br><br>E.M.<br><br><br><br>------------------------------<br><br>_______________________________________________<br>Haskell-Cafe mailing list<br><a ymailto="mailto:Haskell-Cafe@haskell.org" href="mailto:Haskell-Cafe@haskell.org">Haskell-Cafe@haskell.org</a><br><a href="http://www.haskell.org/mailman/listinfo/haskell-cafe" target="_blank">http://www.haskell.org/mailman/listinfo/haskell-cafe</a><br><br><br>End of Haskell-Cafe Digest, Vol 61, Issue 49<br>********************************************<br></div></div><div style="position:fixed"></div></div><br>



      </body></html>