Re: [Haskell-cafe] Haskell Platform + gtk2hs

2009-06-29 Thread Lars Viklund
On Sun, Jun 28, 2009 at 10:41:29PM -0400, John Van Enk wrote: Has any one managed to install gtk2hs on a Windows box running the Haskell Platform? I've had no luck; it seems the gtk2hs installer is unable to find the GHC installation. After some digging, I found a thread on gtk2hs-devel [1]

Re: [Haskell-cafe] List spine traversal

2009-06-29 Thread Martijn van Steenbergen
Tony Morris wrote: Is there a canonical function for traversing the spine of a list? I could use e.g. (seq . length) but this feels dirty, so I have foldl' (const . const $ ()) () which still doesn't feel right. What's the typical means of doing this? (seq . length) doesn't sound that bad to

Re: [Haskell-cafe] coding standard question

2009-06-29 Thread david48
Hello Daniel and all, Your suggestion #1 : Can't import Database.HDBC.MySQL.Connection : da...@pcdavid2:~/projets/haskell/caimonitor$ ghci -Wall Bdd.hs GHCi, version 6.10.3: http://www.haskell.org/ghc/ :? for help Loading package ghc-prim ... linking ... done. Loading package integer ... linking

[Haskell-cafe] XMonad and NetworkManager?

2009-06-29 Thread Ketil Malde
Hi, A bit off-topic, but this is the café, after all... Like many here, I run XMonad as my window manager on top of Linux. On - at least my brand of - Linux, networking is generally handled by NetworkManager, which really needs its associated applet (nm-applet) to work properly. While I

Re: [Haskell-cafe] coding standard question

2009-06-29 Thread Martijn van Steenbergen
Jochem Berndsen wrote: My default is to start developing, then adding -Wall -Werror and make it compile again. That and hlint! Martijn. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe

[Haskell-cafe] [patch] lhaskell.vim update

2009-06-29 Thread Nicolas Wu
I have made some modifications to the lhaskell.vim (v1.04) file to add a feature, and fix up some bugs. I don't know if this is the right place to post for patches, but the file I have claims that the haskell-cafe is the maintainer. First, I made it so that \begin{spec} and \end{spec}

Re: [Haskell-cafe] List spine traversal

2009-06-29 Thread Deniz Dogan
2009/6/29 Martijn van Steenbergen mart...@van.steenbergen.nl: Tony Morris wrote: Is there a canonical function for traversing the spine of a list? I could use e.g. (seq . length) but this feels dirty, so I have foldl' (const . const $ ()) () which still doesn't feel right. What's the

Re: [Haskell-cafe] XMonad and NetworkManager?

2009-06-29 Thread Alexey Khudyakov
On Mon, Jun 29, 2009 at 12:58 PM, Ketil Maldeke...@malde.org wrote: Hi, A bit off-topic, but this is the café, after all... Like many here, I run XMonad as my window manager on top of Linux. On - at least my brand of - Linux, networking is generally handled by NetworkManager, which really

Re: [Haskell-cafe] List spine traversal

2009-06-29 Thread Ketil Malde
Deniz Dogan deniz.a.m.do...@gmail.com writes: What is the spine of a list? Google seems to fail me on this one. A (single-linked) list can be seen as a set of cons cells, where each cell contains two pointers, one to the next cons cell, and one to the cell's data contents ('car' and 'cdr' in

Re: [Haskell-cafe] Re: ANNOUNCE: X Haskell Bindings 0.3

2009-06-29 Thread John Meacham
On Sun, Jun 28, 2009 at 01:12:35PM -0500, Antoine Latter wrote: On Sun, Jun 28, 2009 at 12:52 PM, Antoine Latteraslat...@gmail.com wrote: I'd like to announce the 0.3.* series release of the X Haskell Bindings.  This release, like the prior 0.2.* series focuses on making the API prettier.

Re: [Haskell-cafe] XMonad and NetworkManager?

2009-06-29 Thread Felipe Lessa
On Mon, Jun 29, 2009 at 01:28:47PM +0400, Alexey Khudyakov wrote: I use wicd to manage wireless connections for about three month and I'm pretty happy with it. It seems to be much saner than network manager. Didn't any serious problems with it. I second that. I've gone away from NM because I

[Haskell-cafe] Reflections on Haskell and ICFP Contest 2009

2009-06-29 Thread Rafael Gustavo da Cunha Pereira Pinto
Hi All, As the ICFP 2009 contest (http://www.icfpcontest.org) approaches its end, I decided to write down some thoughts I had while trying. On Friday I downloaded the task (http://www.icfpcontest.org/task-1.9.pdf), read it for a while, and, since my goal is to finish by Xmas, went to the

Re: [Haskell-cafe] XMonad and NetworkManager?

2009-06-29 Thread Zsolt Dollenstein
On Mon, Jun 29, 2009 at 2:27 PM, Felipe Lessafelipe.le...@gmail.com wrote: On Mon, Jun 29, 2009 at 01:28:47PM +0400, Alexey Khudyakov wrote: I use wicd to manage wireless connections for about three month and I'm pretty happy with it. It seems to be much saner than network manager. Didn't any

Re: [Haskell-cafe] Reflections on Haskell and ICFP Contest 2009

2009-06-29 Thread minh thu
Hi Rafael, 2009/6/29 Rafael Gustavo da Cunha Pereira Pinto rafaelgcpp.li...@gmail.com: Hi All, As the ICFP 2009 contest (http://www.icfpcontest.org) approaches its end, I decided to write down some thoughts I had while trying. On Friday I downloaded the task

Re: [Haskell-cafe] Reflections on Haskell and ICFP Contest 2009

2009-06-29 Thread Rafael Gustavo da Cunha Pereira Pinto
Hi Tuh2009/6/29 minh thu not...@gmail.com First step solved. (BTW: I am attaching the first version to this e-mail. I will upload to Hackage upon completion, when getIEEE754float64le and putIEEE754float64le functions are done!) Indeed, I found the binary format a difficulty for haskell.

Re: [Haskell-cafe] coding standard question

2009-06-29 Thread Daniel Fischer
Am Montag 29 Juni 2009 10:47:05 schrieb david48: Hello Daniel and all, Your suggestion #1 : Can't import Database.HDBC.MySQL.Connection : da...@pcdavid2:~/projets/haskell/caimonitor$ ghci -Wall Bdd.hs GHCi, version 6.10.3: http://www.haskell.org/ghc/ :? for help Loading package ghc-prim ...

[Haskell-cafe] ANN: loli: a minimal web dev DSL

2009-06-29 Thread Jinjing Wang
loli is a DSL built on hack. It allows you to easily define routes, build your custom template backends through a simple Template interface, and integrate with other hack middleware. * driver The simplest app looks like this import Network.Loli import Hack.Handler.Happstack

[Haskell-cafe] Haskellers at University of Edinburgh? (hackathon)

2009-06-29 Thread Eric Kow
Hi Haskellers, I'm looking for people at the University of Edinburgh who have a swipe card with access to the Informatics Forum and could hang around on 29 August (or perhaps 6 Sep). Thanks! PS. You may also be interested in some Hackathon news: we've reserved a room at the ICFP venue suitable

[Haskell-cafe] Proper arrival of platform?

2009-06-29 Thread Magnus Therning
When will the Haskell Platform arrive properly? With that I mean, when will GHC stop shipping with a set of base libraries (e.g. network)? /M -- Magnus Therning(OpenPGP: 0xAB4DFBA4) magnus@therning.org Jabber: magnus@therning.org http://therning.org/magnus

Re: [Haskell-cafe] List spine traversal

2009-06-29 Thread Graham Fawcett
On Sun, Jun 28, 2009 at 10:05 PM, Tony Morristonymor...@gmail.com wrote: Is there a canonical function for traversing the spine of a list? I could use e.g. (seq . length) but this feels dirty, so I have foldl' (const . const $ ()) () which still doesn't feel right. What's the typical means of

Re: [Haskell-cafe] coding standard question

2009-06-29 Thread david48
On Mon, Jun 29, 2009 at 3:41 PM, Daniel Fischerdaniel.is.fisc...@web.de wrote: Am Montag 29 Juni 2009 10:47:05 schrieb david48: connecter :: IConnection conn = conn connecter = connectMySQL mysqlInfo And even though I suspect that's the correct type, it fails too : No, that's too general a

[Haskell-cafe] Re: ANN: loli: a minimal web dev DSL

2009-06-29 Thread Simon Michael
Thanks for this! I am using it since yesterday. And also for all the Hack work. I can switch my loli app's back end between happstack and hyena (eg) by changing a single import. Nice. There is a problem with Safari, I think in either loli or hack: at the top of the page you see http headers

Re: [Haskell-cafe] Proper arrival of platform?

2009-06-29 Thread Don Stewart
magnus: When will the Haskell Platform arrive properly? With that I mean, when will GHC stop shipping with a set of base libraries (e.g. network)? Next GHC release. ___ Haskell-Cafe mailing list Haskell-Cafe@haskell.org

[Haskell-cafe] Breaking ghci

2009-06-29 Thread GüŸnther Schmidt
Hi folks, I would like to announce that I have not merely managed to make the RTS choke during runtime on stack overflows like lesser programmers, no, *I* have managed to write code that ghc is not even able to compile due to exhausting virtual memory! Top that! Günther

Re: [Haskell-cafe] Breaking ghci

2009-06-29 Thread Joe Fredette
Code or it didn't happen. :) GüŸnther Schmidt wrote: Hi folks, I would like to announce that I have not merely managed to make the RTS choke during runtime on stack overflows like lesser programmers, no, *I* have managed to write code that ghc is not even able to compile due to exhausting

[Haskell-cafe] ANN: TernaryTrees-0.1.1.1 - An efficient ternary tree implementation of Sets and Maps

2009-06-29 Thread Alex Mason
TernaryTrees is a package that extends Data.Set ad Data.Map with some ternary tree structures, based on the article [http://www.pcplus.co.uk/node/3074/ ] . So far there are three modules: Data.Set.TernarySet, Data.Map.TernaryMap and Data.Set.StringSet, which can hold `Ord a = [a]`, Ord a

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Andrew Coppin
Derek Elkins wrote: On Sun, Jun 28, 2009 at 4:11 PM, Antoine Latteraslat...@gmail.com wrote: On Sun, Jun 28, 2009 at 3:42 PM, Andrew Coppinandrewcop...@btinternet.com wrote: Ah. Apparently it's fixed: http://hackage.haskell.org/trac/hackage/ticket/40 Except that it isn't fixed.

Re: [Haskell-cafe] ANN: TernaryTrees-0.1.1.1 - An efficient ternary tree implementation of Sets and Maps

2009-06-29 Thread Andrew Coppin
Alex Mason wrote: TernaryTrees is a package that extends Data.Set ad Data.Map with some ternary tree structures, based on the article [http://www.pcplus.co.uk/node/3074/] . That's just scary. I was just in the middle of writing the exact same thing! :-D (I read that very article...) Please

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Antoine Latter
On Mon, Jun 29, 2009 at 1:03 PM, Andrew Coppinandrewcop...@btinternet.com wrote: This was not at all clear to me from reading the ticker. OK, so I need to find another seperate tool in order to do this. I guess not every single Haskell user tries to release stuff to Hackage, while presumably

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Andrew Coppin
Antoine Latter wrote: Personally, I've never used runhaskell Setup sdist and I've only ever used cabal sdist. But I'm not sure where I learned that. I think cabal-install is a pretty standard util for people to have, and it ships with the Haskell platform now. So the big hurdle is

Re: [Haskell-cafe] ANN: TernaryTrees-0.1.1.1 - An efficient ternary tree implementation of Sets and Maps

2009-06-29 Thread Felipe Lessa
On Tue, Jun 30, 2009 at 03:29:45AM +1000, Alex Mason wrote: (being able to insert 230,000+ words, check that all those words are actually in the set, write the set out to disk using the Data.Binary instance, reading them back in, and checking the old and new sets are equal takes about 3.5

[Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Justin Bailey
Anyone have thoughts to share? I'd love to read others' experiences but there isn't much coming up with searches or on redditt ... I was happiest with the VM I implemented. Sadly, I wasn't able to solve any of the scenarios, but my VM ran damn fast. That didn't seem to matter so much this year as

Re: [Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread John Meacham
I implemented the VM in C, it was pretty obviously geared towards such an implementation and it took all of an hour. Then I interfaced with it via the FFI. Why use just one language when you can use two? :) I wasn't able to make any time on sunday though so didn't end up submitting a final entry

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Andrew Coppin
Andrew Coppin wrote: Indeed. I've heard a few people claim that cabal-install is the best thing since sliced bread, but I've never touched it. I don't even know where to get it. (Presumably this will become fairly obvious once I go look for it...) Fortunately, it turns out that a trivial

Re: [Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Rafael Gustavo da Cunha Pereira Pinto
I spent too much time reading the files, until today, when Minh Tuh pointed me the right direction on reading the floats... Anyway, I will still keep trying until Xmas :-) On Mon, Jun 29, 2009 at 15:40, Justin Bailey jgbai...@gmail.com wrote: Anyone have thoughts to share? I'd love to read

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Jason Dagit
On Mon, Jun 29, 2009 at 11:57 AM, Andrew Coppin andrewcop...@btinternet.com wrote: Andrew Coppin wrote: Indeed. I've heard a few people claim that cabal-install is the best thing since sliced bread, but I've never touched it. I don't even know where to get it. (Presumably this will become

Re: [Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Brent Yorgey
On Mon, Jun 29, 2009 at 11:40:28AM -0700, Justin Bailey wrote: Anyways, for those who care, the heart of my VM implementation was a monadic fold over the program, with a mutable array representing the machine's memory, all inside ''runSTUArray.'' I used a simple data type to represent the

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Antoine Latter
On Mon, Jun 29, 2009 at 2:12 PM, Jason Dagitda...@codersbase.com wrote: I can't say for certain, but just reading the output it looks like it created a tarball in a temporary folder (that worked) and then when it tried to clean it up it failed.  Sounds like a bug report is in order. You may

Re: [Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Miguel Mitrofanov
I was excited when I read about the VM - I'd imagined all sorts of cool things, like assembler, linker, compiler (for something C-like), maybe even debugger... And what a disappointment it was when I understood that nothing of this kind is needed. On 29 Jun 2009, at 22:55, John Meacham

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Andrew Coppin
Jason Dagit wrote: On Mon, Jun 29, 2009 at 11:57 AM, Andrew Coppin andrewcop...@btinternet.com mailto:andrewcop...@btinternet.com wrote: Rather less fortunately, it still doesn't actually fix my problem: E:\Haskell\AOC-HalfIntegercabal configure Resolving dependencies...

Re: [Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread John Meacham
On Mon, Jun 29, 2009 at 11:51:43PM +0400, Miguel Mitrofanov wrote: I was excited when I read about the VM - I'd imagined all sorts of cool things, like assembler, linker, compiler (for something C-like), maybe even debugger... And what a disappointment it was when I understood that nothing

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Ross Mellgren
I presume that many of the developers do not have windows machines (presumably because windows sucks). Maybe you could help them by trying to track down where the error in the code is, and even better yet submitting a patch? This is all free by the virtue of people giving what time they

[Haskell-cafe] Haskell Weekly News: Issue 123 - June 29, 2009

2009-06-29 Thread Brent Yorgey
--- Haskell Weekly News http://sequence.complete.org/hwn/20090629 Issue 123 - June 29, 2009 --- Welcome to issue 123 of HWN, a newsletter covering

Re: [Haskell-cafe] Proper arrival of platform?

2009-06-29 Thread Magnus Therning
Don Stewart wrote: magnus: When will the Haskell Platform arrive properly? With that I mean, when will GHC stop shipping with a set of base libraries (e.g. network)? Next GHC release. Excellent, exactly the kind of answer I was hoping for. That release can't come too soon as far as I'm

Re: [Haskell-cafe] Re: FFI and heap memory usage limit

2009-06-29 Thread Duncan Coutts
On Fri, 2009-06-26 at 13:00 +0100, Simon Marlow wrote: Maybe bzlib allocates using malloc()? That would not be tracked by GHC's memory management, but could cause OOM. Yes it does. Another problem is that if you ask for a large amount of memory in one go, the request is usually honoured

Re: [Haskell-cafe] Re: Could FFI support pass-by-value of structs?

2009-06-29 Thread Duncan Coutts
On Wed, 2009-06-24 at 18:48 -0700, John Meacham wrote: On Wed, Jun 24, 2009 at 10:23:29AM -0300, Maurí­cio wrote: However, isn't just knowing the size and alignment enough to write a generic struct handler that, by using the appropriate calling convention, is going to work with any struct?

Re: [Haskell-cafe] Re: FFI and heap memory usage limit

2009-06-29 Thread Don Stewart
duncan.coutts: On Fri, 2009-06-26 at 13:00 +0100, Simon Marlow wrote: Maybe bzlib allocates using malloc()? That would not be tracked by GHC's memory management, but could cause OOM. Yes it does. Another problem is that if you ask for a large amount of memory in one go, the

Re[2]: [Haskell-cafe] Re: Could FFI support pass-by-value of structs?

2009-06-29 Thread Bulat Ziganshin
Hello Duncan, Tuesday, June 30, 2009, 12:03:15 AM, you wrote: struct ex { int x; int y; int z; }; ex example_functions (ex p) afaik, there is C ABI, that defines how to pass and return parameters of simple types, it's common for all compilers supporting so-called cdecl on

[Haskell-cafe] [: Where the bracket things are? :]

2009-06-29 Thread Paul Keir
I'd like to add my own custom list delimiters to ghc; such as the [: and :] of Data Parallel Haskell. The purpose is mainly to learn a little about GHC's internals. Any suggestions on the GHC files I should look at first? Alternatively, maybe this is actually possible from outside the

Re: [Haskell-cafe] Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Miguel Mitrofanov
On 30 Jun 2009, at 00:03, John Meacham wrote: The fact it didn't have any looping meant that it wasn't even fully turing complete and you probably couldn't speed it up much anyway, it already had an intrinsically short running time. Exactly! That's an ideal situation, you don't have to

Re: [Haskell-cafe] [: Where the bracket things are? :]

2009-06-29 Thread Robert Greayer
You can use QuasiQuotation, where your bracketing syntax looks like: [$foo| blah blah blah |] and 'foo' represents a quasi-quoter, and the stuff inside the brackets is any arbitrary syntax recognized by it.

[Haskell-cafe] INAP 2009: DEADLINE EXTENSION and Final Call for Papers

2009-06-29 Thread Pedro Salgueiro
--- (PLEASE DISTRIBUTE -- **DEADLINE EXTENDED** -- PLEASE DISTRIBUTE) --- Final Call for Papers INAP 2009

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Andrew Coppin
Ross Mellgren wrote: I presume that many of the developers do not have windows machines (presumably because windows sucks). Maybe you could help them by trying to track down where the error in the code is, and even better yet submitting a patch? This is all free by the virtue of people

Re: [Haskell-cafe] Cabal fun [Half-integer]

2009-06-29 Thread Jason Dagit
On Mon, Jun 29, 2009 at 12:55 PM, Andrew Coppin andrewcop...@btinternet.com wrote: This is an exercise in pure frustration! Sometimes it seems as if *everything* is broken on Windows. In my opinion you're right, Windows, and things built on it, tend to be very broken. Maybe that's why so

[Haskell-cafe] Re: Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Ahn, Ki Yung
Similar to mine except that I implemented with all of the memory (data, instruction, input and output ports) with the Data.Map library. One thing to care about is the heap memory profiling. You'll need to make sure that Map.insert function do not pile up as thunk. This is a typical memory

[Haskell-cafe] Re: Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Ahn, Ki Yung
John Meacham 쓴 글: I implemented the VM in C, it was pretty obviously geared towards such an implementation and it took all of an hour. Then I interfaced with it via the FFI. Why use just one language when you can use two? :) You could also have used Data.Binary. That's what I did. I wasn't

Re: Re[2]: [Haskell-cafe] Re: Could FFI support pass-by-value of structs?

2009-06-29 Thread Duncan Coutts
On Tue, 2009-06-30 at 00:45 +0400, Bulat Ziganshin wrote: Hello Duncan, Tuesday, June 30, 2009, 12:03:15 AM, you wrote: struct ex { int x; int y; int z; }; ex example_functions (ex p) afaik, there is C ABI, that defines how to pass and return parameters of

[Haskell-cafe] ANN: package Boolean: Generalized booleans

2009-06-29 Thread Conal Elliott
I just uploaded a new package [1] for generalized booleans, which provides type classes with generalizations of boolean values operations, if-then-else, Eq and Ord. These values types come up for me with every new deep DSEL, and I think they do for others as well. The design space has some

Re: [Haskell-cafe] ANN: TernaryTrees-0.1.1.1 - An efficient ternary tree implementation of Sets and Maps

2009-06-29 Thread ajb
G'day all. Quoting Andrew Coppin andrewcop...@btinternet.com: That's just scary. I was just in the middle of writing the exact same thing! :-D (I read that very article...) When you're both done, please compare with the implementation that's been in Edison for about five years:

Re: [Haskell-cafe] Reflections on Haskell and ICFP Contest 2009

2009-06-29 Thread Lanny Ripple
When you get bored or stumped with the problem you might pass your time with Orbiter [http://orbit.medphys.ucl.ac.uk/]. Or you could just use all the orbital mechanics math from the documentation. :) Enjoy, -ljr Rafael Gustavo da Cunha Pereira Pinto wrote: Hi All, As the ICFP 2009

Re: [Haskell-cafe] Reflections on Haskell and ICFP Contest 2009

2009-06-29 Thread Rafael Gustavo da Cunha Pereira Pinto
2009/6/29 Lanny Ripple la...@cisco.com When you get bored or stumped with the problem you might pass your time with Orbiter [http://orbit.medphys.ucl.ac.uk/]. Or you could just use all the orbital mechanics math from the documentation. :) Enjoy, -ljr That's cool... I'll try it

[Haskell-cafe] Wondering about c type in haskell.

2009-06-29 Thread Magicloud Magiclouds
Hi, There are times, when we need to make some system calls, or call C library. So we have to deal with C data types. For example, CPid, which is an integer, actually. So we can do fromIntegral pid. Then why do not we define type CPid = Integer, and convert Haskell Integer with C Int

Re: [Haskell-cafe] List spine traversal

2009-06-29 Thread Geoffrey Marchant
I think I can see the point of forcing a list without forcing the actual data, but is there a way to do this that works on circular lists as well? On Mon, Jun 29, 2009 at 3:30 AM, Ketil Malde ke...@malde.org wrote: Deniz Dogan deniz.a.m.do...@gmail.com writes: What is the spine of a list?

[Haskell-cafe] Re: Wondering about c type in haskell.

2009-06-29 Thread Ahn, Ki Yung
Magicloud Magiclouds 쓴 글: Hi, There are times, when we need to make some system calls, or call C library. So we have to deal with C data types. For example, CPid, which is an integer, actually. So we can do fromIntegral pid. Then why do not we define type CPid = Integer, and convert Haskell

[Haskell-cafe] Re: Wondering about c type in haskell.

2009-06-29 Thread Ahn, Ki Yung
Ahn, Ki Yung 쓴 글: Magicloud Magiclouds 쓴 글: Hi, There are times, when we need to make some system calls, or call C library. So we have to deal with C data types. For example, CPid, which is an integer, actually. So we can do fromIntegral pid. Then why do not we define type CPid = Integer,

Re: [Haskell-cafe] Wondering about c type in haskell.

2009-06-29 Thread Jason Dagit
On Mon, Jun 29, 2009 at 7:01 PM, Magicloud Magiclouds magicloud.magiclo...@gmail.com wrote: Hi, There are times, when we need to make some system calls, or call C library. So we have to deal with C data types. For example, CPid, which is an integer, actually. So we can do fromIntegral

Re: [Haskell-cafe] Re: Reflections on the ICFP 2009 programming contest

2009-06-29 Thread Eugene Kirpichov
We implemented the VM by writing a smallish compiler to C for it in Haskell. It ran *damn* fast, but we couldn't get rid of some bug that did not let us run the 4rth task at all, although the others worked fine :( 2009/6/30 Ahn, Ki Yung kya...@gmail.com: John Meacham 쓴 글: I implemented the VM

Re: [Haskell-cafe] Re: Wondering about c type in haskell.

2009-06-29 Thread Magicloud Magiclouds
I think Integer is prefered in Haskell. I mean normally, I should use it in my code. So following my example, why cannot CPid be treated as Integer. Only when it needs to be transfered to C or whatsoever, we convert it to Long or whatsoever. So we have a unified type system, not a bunch of types I

Re: [Haskell-cafe] Wondering about c type in haskell.

2009-06-29 Thread Magicloud Magiclouds
That is true. But I think we could avoid (or resolve) the problem of wrong type thing in other ways, or we just resolve one thing by typing much more code. On Tue, Jun 30, 2009 at 11:37 AM, Jason Dagitda...@codersbase.com wrote: On Mon, Jun 29, 2009 at 7:01 PM, Magicloud Magiclouds

[Haskell-cafe] Leksah works!

2009-06-29 Thread Eugene Kirpichov
Hi. Quite a while ago I launched Leksah and couldn't get anything done at all; so I thought it is probably never be completed and abandoned attempts to find an IDE for Haskell. However, 3 days ago I launched the new version and it works fantastic! It has an IntelliSense popup with type

[Haskell-cafe] Making a strict (non-lazy) GCL Interpreter

2009-06-29 Thread Hector Guilarte
Hi everyone! (First of all, I don't know Monads!) I made a GCL (Guarded Command Language) Compiler and Interpreter for my Languages and Machines course in my University with alex, happy and ghc. I asked about a week ago about the use of unsafePerformIO for that same project, now I have two new