>>>>> "Keith" == Keith Wansbrough <[EMAIL PROTECTED]> writes: Keith> Jerzy Karczmarczuk <[EMAIL PROTECTED]> writes: >> Macros in Scheme are used to unfold n-ary control structures such as COND >> into a hierarchy of IFs, etc. Nothing (in principle) to do with laziness >> or HO functions. Keith> Isn't this exactly the reason that macros are less necessary in Keith> lazy languages? Keith> In Haskell you can write Keith> myIf True x y = x Keith> myIf False x y = y Sure, but you're relying on pattern matching to implement the semantics of myIf, which already is a generalized conditional. In Scheme, where pattern matching is not primitive, you can get it through a macro. The same holds for things like DO notation or list comprehensions, where apparently lazy evaluation by itself doesn't help implementing convenient syntax atop a more primitive underlying notion. -- Cheers =8-} Mike Friede, V�lkerverst�ndigung und �berhaupt blabla _______________________________________________ Haskell-Cafe mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell-cafe
Re: Macros (Was: Interesting: "Lisp as a competitive advantage")
Michael Sperber [Mr. Preprocessor] Mon, 07 May 2001 01:33:29 -0700
- Macros (Was: Interesting: "Lisp as... Jerzy Karczmarczuk
- Re: Macros (Was: Interesting: &quo... Keith Wansbrough
- Re: Macros (Was: Interesting: ... Jerzy Karczmarczuk
- Re: Macros (Was: Interesting: ... Michael Sperber [Mr. Preprocessor]
- Re: Macros (Was: Interesting: &quo... Marcin 'Qrczak' Kowalczyk
- Re: Macros (Was: Interesting: &quo... Fergus Henderson
- Re: Macros Ronny Wichers Schreur
