reading in ghci-6-4-branch

2005-06-22 Thread Serge D. Mechveliani
Who knows, please, how to work with the program of main = interact (\ s - shows (read s :: Bool) \n) in the interpreter ghci ? This is on ghc-cvs-6-4-branch-June-15-2005 under Debian Linux, i386-uknown. When compiled, it works:ghc --make ReadBug

Re: reading in ghci-6-4-branch

2005-06-22 Thread Bernard Pope
On Wed, 2005-06-22 at 11:04 +0400, Serge D. Mechveliani wrote: Who knows, please, how to work with the program of main = interact (\ s - shows (read s :: Bool) \n) Is this a GHC bug? Regards, Hi Serge, Generally speaking differences that you see between the interactive behaviour of

RE: Bignums in Haskell

2005-06-22 Thread Simon Peyton-Jones
There's nothing inherently imperative about bignums. The current algorithms may have an imperative flavour, but that may be partly because that's what suits the implementation language. If the algorithms are divide-and-conquer, perhaps a tree representation would work very nicely. And even in

bignum libraries

2005-06-22 Thread Serge D. Mechveliani
People, When intending to write a library for large numbers, it worths to keep in mind the following. 1. Efficient multiplication, division and gcd methods may occur rather involved mathematically. 2. It is natural for `arithmetics' to include factorization. Suppose, GHC would like to

comparing 5.02.3 and 6-4-branch

2005-06-22 Thread Serge D. Mechveliani
I have installed ghc-5.02.3 and ghc-cvs-6-4-branch-June-15 on the same Linux machine, ported DoCon to 6-4-branch, and compared DoCon-2.06 - ghc-5.02.3 to DoCon-2.09 - ghc-cvs-6-4-branch-June-15 on computer algebra (the CA algorithms are the same). 1. They work correct. 2. The

Re: bignum libraries

2005-06-22 Thread Jerzy Karczmarczuk
Serge D. Mechveliani wrote: 3. It is natural to extend further the library to algebraic numbers. Bignum arithmetics and algebraic numbers are worlds apart. Sergey - as always - is ambitious to perfection. That's good, but let people do the basics first... Jerzy Karczmarczuk

Re: [Haskell] A MonadPlusT with fair operations and pruning

2005-06-22 Thread ajb
G'day all. Quoting [EMAIL PROTECTED]: : Since Andrew Bromage wished for that interesting monad, perhaps he has : in mind a good example of its use. We are particularly interested in a : short example illustrating soft-cut (and, perhaps, `once'). No obvious small examples of soft cut spring to

Re: [Haskell] Haskell version of Crystal Space 3D?

2005-06-22 Thread Manuel M T Chakravarty
Benjamin L. Russell: Does anybody know any Haskell tool(s) corresponding to Crystal Space 3D ( see http://www.crystalspace3d.org/tikiwiki/tiki-view_articles.php )? The simplest solution would probably be to write a Haskell binding to the Crystal Space 3D library. However, as Crystal Space 3D

Re: [Haskell] Haskell version of Crystal Space 3D?

2005-06-22 Thread Sebastian Sylvan
On 6/21/05, Benjamin L. Russell [EMAIL PROTECTED] wrote: Does anybody know any Haskell tool(s) corresponding to Crystal Space 3D ( see http://www.crystalspace3d.org/tikiwiki/tiki-view_articles.php )? To quote from About Crystal Space ( see

Re: [Haskell] Haskell version of Crystal Space 3D?

2005-06-22 Thread robert dockins
Two questions: 1) Would a Haskell counterpart to Crystal Space 3D, if implemented, potentially be fast enough to run a project similar to the 3D real-time Crystal Space 3D-based MMORPG PlaneShift ( see http://www.planeshift.it/main_01.html ) on Mac OS X 10.2.8 Jaguar or above? 2) For a hobbyist

Re: [Haskell] Haskell version of Crystal Space 3D?

2005-06-22 Thread Benjamin L. Russell
--- Sebastian Sylvan [EMAIL PROTECTED] wrote: I haven't looked at Crystal Space in a while, but does it have some sort of scripting interface? According to About Crystal Space ( see http://www.crystalspace3d.org/tikiwiki/tiki-index.php?page=About+Crystal+Space ), Crystal Space 3D reportedly

Re: [Haskell] Haskell version of Crystal Space 3D?

2005-06-22 Thread Benjamin L. Russell
--- robert dockins [EMAIL PROTECTED] wrote: As it turns out, there is a pretty large conceptual gap between the design of most object oriented libraries and idiomatic Haskell. This makes writing useful bindings in Haskell for such libraries a tricky business. If you want it to be

Re: [Haskell] Haskell version of Crystal Space 3D?

2005-06-22 Thread Sebastian Sylvan
On 6/22/05, Benjamin L. Russell [EMAIL PROTECTED] wrote: Two questions: 1) Would a Haskell counterpart to Crystal Space 3D, if implemented, potentially be fast enough to run a project similar to the 3D real-time Crystal Space 3D-based MMORPG PlaneShift ( see

[Haskell] Dynamic binding

2005-06-22 Thread Andrew Ward
Hi All, In Simon Thompson's The Craft of Functional Programming Second Edition, page 226, it is mentioned that Laufer (1996) describes a Haskell extension to allow dynamic binding. I was wondering if this has been implemented as an extension in any of the haskell compilers, or variants? I am a

Re: [Haskell] Dynamic binding

2005-06-22 Thread Andrew Ward
Pal-Kristian Engstad wrote: On Wednesday 22 June 2005 05:38 pm, Andrew Ward wrote: What would be the normal way for a Haskell programmer to handle the typical shape example in beginner OO tutorials? By not doing OO. You have to ask yourself, what is the purpose and/or benefit of

RE: [Haskell] Dynamic binding

2005-06-22 Thread Ralf Lammel
At the risk of being excluded from this list (because of an unmoral number of plugs about OOHaskell), here we go: http://homepages.cwi.nl/~ralf/OOHaskell/ You might start with the appendices of the paper and also read Section 2 which finally implements the Shapes example with ease. The C++

[Haskell-cafe] Compiling ghc with openal

2005-06-22 Thread Ron
Hi, I am configuring ghc from source(no Ports(since that is broken for this purpose too)) on freebsd 5.4: CPPFLAGS=-I/usr/X11R6/include/ -I/usr/local/include/ -L/usr/local/lib/./configure I had issues with opengl, which were resolved by adding the first dir to CPPFLAGS, but it seems

[Haskell-cafe] Noob error: Type b - c b Does not match IO a

2005-06-22 Thread kynn
--text follows this line-- I'm trying to learn Haskell from YAHT. My attempt at a solution of Exercise 3.10 is failing with a Type does not match error. The exercise is to write a function that will read numbers (one per line) from the command line, until the number 0 is entered. At this

Re: [Haskell-cafe] Noob error: Type b - c b Does not match IO a

2005-06-22 Thread Bernard Pope
On Thu, 2005-06-23 at 00:17 -0400, [EMAIL PROTECTED] wrote: printFact [] = return printFact (x:xs) = do -- triggers error message putStrLn (x ++ factorial is ++ fact x) printFact xs return If anyone can explain to me how to fix this error I'd appreciate it. You forgot to return a

Re: [Haskell-cafe] Noob error: Type b - c b Does not match IO a

2005-06-22 Thread kynn
From: Bernard Pope [EMAIL PROTECTED] Cc: haskell-cafe@haskell.org On Thu, 2005-06-23 at 00:17 -0400, [EMAIL PROTECTED] wrote: You forgot to return a value. ... Much appreciated! kj ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org