[Haskell-cafe] RE: Troubles with FFI

2006-05-15 Thread SevenThunders
Done! Thanks for the tip. I added a wiki page on this with my overly simple examples. Perhaps I'll extend it as I learn more. http://www.haskell.org/hawiki/FfiWithArrays -- View this message in context: http://www.nabble.com/Troubles-with-FFI-t1611744.html#a4402742 Sent from the Haskell - Has

Re: [Haskell-cafe] Troubles with FFI

2006-05-15 Thread SevenThunders
Yup I'm aware of it, and I'd love to use it. The only problem is that it's highly linux/unix specific as far as I can tell. Even the graphics libraries it uses only runs on 'nix right now. I just tried to load graphics.hgl and hello world program crashed GHCi and doesn't compile under the regul

RE: [Haskell-cafe] Troubles with FFI

2006-05-15 Thread Tim Newsham
Matthew, the entire Haskell.org website is a Wiki. You might spare someone else the pain that you went through by starting a "Duffers guide to the Haskell FFI" that contains the information you wished you'd known on day 1. I'm sure you'd get lots of help on the #haskell IRC if you did so. The

RE: [Haskell-cafe] Troubles with FFI

2006-05-15 Thread Donn Cave
On Mon, 15 May 2006, Simon Peyton-Jones wrote: > | > the automated ones, seemed to handle the case of passing numerical > | > arrays to C, and having them get updated and passed back. That is > my > | > primary interest in the FFI and yet no obvious solution or example > | > could be found after d

Re: [Haskell-cafe] Newbie:Debugging and Overgeneralization

2006-05-15 Thread Robert Dockins
On May 15, 2006, at 11:14 AM, Aditya Siram wrote: I have been working with a Haskell text for the past couple of months or so and I have some general problem solving questions. 1. Is there a way to output intermediate values of a calculation? As an imperative programmer I have become used

Re: [Haskell-cafe] Newbie:Debugging and Overgeneralization

2006-05-15 Thread Neil Mitchell
Hi Deech, 1. Is there a way to output intermediate values of a calculation? Debug.Trace.trace is what you want, its not quite as convenient (or safe) as cout, but its usually good enough. If you want to see more detail then Hat (http://www.haskell.org/hat) is probably what you want. From a ge

[Haskell-cafe] Newbie:Debugging and Overgeneralization

2006-05-15 Thread Aditya Siram
I have been working with a Haskell text for the past couple of months or so and I have some general problem solving questions. 1. Is there a way to output intermediate values of a calculation? As an imperative programmer I have become used to using "System.out"'s or 'cout's to check that my fu

Re: [Haskell-cafe] dumb monad syntax question

2006-05-15 Thread Malcolm Wallace
> I've been reading Phil Wadler's monad papers from the early '90s, > and it's been interesting to see how the monad concept evolved over > the course of those years. > But I haven't been able to track down the first use of the "do" notation for > monads. Can anyone tell me where that came from?

Re: [Haskell-cafe] Linspire/Freespire Core OS Team and Haskell

2006-05-15 Thread Bulat Ziganshin
Hello Clifford, Saturday, May 13, 2006, 9:28:56 PM, you wrote: > The OS team at Linspire, Inc. would like to announce that we are > standardizing on Haskell as our preferred language for core OS development. it's fantastic! i well know about Lindows and never think that so interesting packages

Re: [Haskell-cafe] dumb monad syntax question

2006-05-15 Thread Bulat Ziganshin
Hello mvanier, Monday, May 15, 2006, 7:04:11 AM, you wrote: > I've been reading Phil Wadler's monad papers from the early '90s, and it's > been > interesting to see how the monad concept evolved over the course of those > years. > But I haven't been able to track down the first use of the "do

Re[2]: [Haskell-cafe] Troubles with FFI

2006-05-15 Thread Bulat Ziganshin
Hello Donald, Saturday, May 13, 2006, 11:47:34 AM, you wrote: > * Visit haskell.org > * Click on "Books and tutorials" > * Scroll to "Using Monads" > * First entry in the list is this paper. but novices don't know what monads is a Haskell way to do I/O and interface with C! >> It was ce

Re: [Haskell-cafe] Re: Existentially-quantified constructors: Hugs is fine, GHC is not?

2006-05-15 Thread Ross Paterson
On Thu, May 11, 2006 at 01:46:43PM +0100, Ben Rudiak-Gould wrote: > Otakar Smrz wrote: > > data ... = ... | forall b . FMap (b -> a) (Mapper s b) > > > > ... where FMap qf qc = stripFMap f q > > > >the GHC compiler as well as GHCi (6.4.2 and earlier) issue an error > > > >My brain just expl

Re: [Haskell-cafe] Troubles with FFI

2006-05-15 Thread Henning Thielemann
On Sat, 13 May 2006, Matthew Bromberg wrote: > So after about 10 hours of wrestling with syntax, including messing up > the initial capitalization of module names, indenting in do lists, > forgetting to put commas in tuples and lists I finally got the following > example to compile without error

RE: [Haskell-cafe] Troubles with FFI

2006-05-15 Thread Simon Peyton-Jones
| > the automated ones, seemed to handle the case of passing numerical | > arrays to C, and having them get updated and passed back. That is my | > primary interest in the FFI and yet no obvious solution or example | > could be found after days of internet searching and pouring over | > tutorials