extending bang proposal Re: strict Haskell dialect

2006-02-06 Thread Bulat Ziganshin
Hello Ketil, Monday, February 06, 2006, 4:06:35 PM, you wrote: foo :: !Int - !Int KM (Is the second ! actually meaningful?) yes! it means that the function is strict in its result - i.e. can't return undefined value when strict arguments are given. this sort of knowledge should help a

Re: strict Haskell dialect

2006-02-04 Thread Tomasz Zielonka
On Thu, Feb 02, 2006 at 11:46:56PM +0100, Wolfgang Jeltsch wrote: Am Mittwoch, 1. Februar 2006 11:49 schrieb Bulat Ziganshin: [...] i had one idea, what is somewhat corresponding to his discussion: make a strict Haskell dialect. implement it by translating all expressions of form f x

Re: strict Haskell dialect

2006-02-04 Thread Ben Rudiak-Gould
Chris Kuklewicz wrote: Weak uses seq to achieve WHNF for it's argument newtype Weak a = WeakCon {runWeak :: a} mkWeak x = seq x (WeakCon x) unsafeMkWeak x = WeakCon x This doesn't actually do what you think it does. mkWeak and unsafeMkWeak are the same function. mkWeak 123 = seq 123

Re[2]: strict Haskell dialect

2006-02-04 Thread Bulat Ziganshin
Hello Tomasz, Saturday, February 04, 2006, 12:39:38 PM, you wrote: make a strict Haskell dialect. TZ I am with you. If Haskell switches to strictness, as i said, strict _dialect_ is interesting for optimization, moving from other languages and making strict variants of data structures

Re: [Haskell-cafe] Re[2]: strict Haskell dialect

2006-02-04 Thread Jan-Willem Maessen
On Feb 3, 2006, at 8:16 PM, Brian Hulley wrote: Jan-Willem Maessen wrote: I pointed out some problems with strict Haskell in a recent talk, but I think it'd be worth underscoring them here in this forum. Is the text of this talk or points raised in it available online anywhere? snip

Re[2]: strict Haskell dialect

2006-02-03 Thread Bulat Ziganshin
Hello Wolfgang, Friday, February 03, 2006, 1:46:56 AM, you wrote: i had one idea, what is somewhat corresponding to this discussion: make a strict Haskell dialect. implement it by translating all expressions of form f x into f $! x and then going to the standard (lazy) haskell translator

Re: [Haskell-cafe] Re[2]: strict Haskell dialect

2006-02-03 Thread John Meacham
On Fri, Feb 03, 2006 at 07:33:12PM -, Brian Hulley wrote: One question is how to get some kind of do notation that would work well in a strict setting. The existing do notation makes use of lazyness in so far as the second arg of is only evaluated when needed. Perhaps a new keyword

Re[2]: strict Haskell dialect

2006-02-02 Thread Bulat Ziganshin
Hello John, Thursday, February 02, 2006, 4:24:06 AM, you wrote: It can, but so far it's really ugly to apply transformations to entire modules. A little syntactic sugar could be good there. JM module $hat.Foo(..) where JM ... JM could mean pass the entire module through the 'hat' function of

Re: strict Haskell dialect

2006-02-02 Thread Wolfgang Jeltsch
Am Mittwoch, 1. Februar 2006 11:49 schrieb Bulat Ziganshin: [...] i had one idea, what is somewhat corresponding to his discussion: make a strict Haskell dialect. implement it by translating all expressions of form f x into f $! x and then going to the standard (lazy) haskell translator

strict Haskell dialect

2006-02-01 Thread Bulat Ziganshin
. Lazy by default is more in the spirit of JM haskell. i had one idea, what is somewhat corresponding to his discussion: make a strict Haskell dialect. implement it by translating all expressions of form f x into f $! x and then going to the standard (lazy) haskell translator. the same for data