Re: [Haskell-cafe] Best way to build strings?

2005-07-21 Thread Tomasz Zielonka
On Thu, Jul 21, 2005 at 04:55:15PM +1000, Bernard Pope wrote: On Wed, 2005-07-20 at 17:06 +0100, Andy Gimblett wrote: show (Prefix l p) = ( ++ l ++ - ++ show p ++ ) show (External p q) = ( ++ show p ++ [] ++ show q ++ ) but to me the extensive use of ++ is not particularly

Re: [Haskell-cafe] Updating the Haskell Standard

2005-07-21 Thread Bulat Ziganshin
Hello John, Wednesday, July 20, 2005, 10:14:23 PM, you wrote: JG It has been awhile since I wrote a Haskell program that can compile in JG pure Haskell 98 mode. I think it would benefit everyone if a more JG up-to-date standard were made available. imho, there is an unofficial standard made by

Re[2]: [Haskell-cafe] Re: FFI and callbacks

2005-07-21 Thread Bulat Ziganshin
Hello Simon, Thursday, July 21, 2005, 1:16:10 AM, you wrote: However, if one of my Haskell-based callbacks creates new threads with forkIO, I could be in trouble; if they make any calls into C, a new bound OS thread would be created for them, and this could wind up causing trouble in C. I

Re: [Haskell-cafe] Updating the Haskell Standard

2005-07-21 Thread Sam Goldman
(oops, forgot to cc to the list) Bulat Ziganshin wrote: Hello John, Wednesday, July 20, 2005, 10:14:23 PM, you wrote: JG It has been awhile since I wrote a Haskell program that can compile in JG pure Haskell 98 mode. I think it would benefit everyone if a more JG up-to-date standard

Re: [Haskell-cafe] Best way to build strings?

2005-07-21 Thread Bernard Pope
On Thu, 2005-07-21 at 09:24 +0200, Tomasz Zielonka wrote: On Thu, Jul 21, 2005 at 04:55:15PM +1000, Bernard Pope wrote: On Wed, 2005-07-20 at 17:06 +0100, Andy Gimblett wrote: show (Prefix l p) = ( ++ l ++ - ++ show p ++ ) show (External p q) = ( ++ show p ++ [] ++ show q ++ )

RE: [Haskell-cafe] Updating the Haskell Standard

2005-07-21 Thread Simon Peyton-Jones
| I think an updated standard is overdue. I find it difficult anymore to | write any but the most trivial of programs using pure Haskell 98. Some | notable, and widely-used, features developed since then include: | | * Overlapping instances | * FFI | * Hierarchical namespace | * Undecidable

RE: [Haskell-cafe] Updating the Haskell Standard

2005-07-21 Thread Bernard Pope
On Thu, 2005-07-21 at 09:39 +0100, Simon Peyton-Jones wrote: In fact there's a well established way to express the results of such an exercise: an Addendum to the Report. Two of the things you mention here already are Addenda http://haskell.org/definition/ namely FFI and hierarchical

RE: Re[2]: [Haskell-cafe] Re: FFI and callbacks

2005-07-21 Thread Simon Marlow
On 21 July 2005 08:07, Bulat Ziganshin wrote: Hello Simon, Thursday, July 21, 2005, 1:16:10 AM, you wrote: However, if one of my Haskell-based callbacks creates new threads with forkIO, I could be in trouble; if they make any calls into C, a new bound OS thread would be created for them,

Re: [Haskell-cafe] Re: FFI and callbacks

2005-07-21 Thread John Goerzen
On Thu, Jul 21, 2005 at 11:07:15AM +0400, Bulat Ziganshin wrote: Hello Simon, Thursday, July 21, 2005, 1:16:10 AM, you wrote: SM from a single thread. you can either: 1) made all calls from single thread 2) put all calls in withMVar lock, where `lock` is a global MVar OK, that makes

Re: [Haskell-cafe] Re: FFI and callbacks

2005-07-21 Thread Lemmih
On 7/21/05, John Goerzen [EMAIL PROTECTED] wrote: On Thu, Jul 21, 2005 at 11:07:15AM +0400, Bulat Ziganshin wrote: Hello Simon, Thursday, July 21, 2005, 1:16:10 AM, you wrote: SM from a single thread. you can either: 1) made all calls from single thread 2) put all calls in

Re[2]: [Haskell-cafe] Re: FFI and callbacks

2005-07-21 Thread Bulat Ziganshin
Hello John, Thursday, July 21, 2005, 4:20:16 PM, you wrote: you can either: 1) made all calls from single thread 2) put all calls in withMVar lock, where `lock` is a global MVar JG OK, that makes sense. Simon Marlow has corrected me :) JG 1. It seems that there is no function that says

Re: [Haskell-cafe] Updating the Haskell Standard

2005-07-21 Thread Brian Smith
On 7/20/05, John Goerzen [EMAIL PROTECTED] wrote: There was a brief discussion on #haskell today about the Haskell standard. I'd like to get opinions from more people, and ask if there is any effort being done in this direction presently. I think an updated standard is overdue. I find it

Re: [Haskell-cafe] Updating the Haskell Standard

2005-07-21 Thread ajb
G'day all. Quoting Brian Smith [EMAIL PROTECTED]: Even if undecidable instances was standardized, would we want it turned on by default? I am trying to write real programs in Haskell and I have never even comtemplated using undecidable instances. There's only one situation where I've found

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

2005-07-21 Thread ajb
G'day all. Quoting [EMAIL PROTECTED]: We chose c === (true; true), t' === e' === fail, t === e === true. Thus, Good point. It becomes even more obvious when you have a monad transformer. If e === (lift m), then this: mif (mif c t' e') t e translates to (lift m), but this: mif c (\x -

Re: [Haskell-cafe] Re: Lists vs. Monads

2005-07-21 Thread oleg
Jonathan Cast wrote: ] You can't define most initial models without recursive (or ] inductive) data types in general, because initial models are defined ] inductively. ] You can't define head, tail, or foldr using the MonadPlus ] signature ] OK. Right. I forgot about the Church