[Haskell-cafe] Haskell symbol ~

Jonathan Cast jonathanccast at fastmail.fm
Wed Aug 27 15:14:13 EDT 2008


On Wed, 2008-08-27 at 20:14 +0100, C.M.Brown wrote:
> Hi,
> 
> I may be wrong here, but I don't belive it's just let-patterns that have
> this property. I.e. what's the difference between...
> 
> (Just x) = _|_
> 
> f = x
> 
> vs.
> 
> f = let (Just x) = _|_ in x
> 
> vs.
> 
> f = x where (Just x) = _|_
> 
> I believe Haskell uses Normal Order Reduction in all these cases. Why is
> it just let-patterns? Can you give an example?

Those are all syntax sugar for let patterns.

jcc




More information about the Haskell-Cafe mailing list