Am Montag, den 05.11.2007, 17:42 +0100 schrieb Sunnan: > Mark Fredrickson wrote: > > > > Here's a related question for more experienced Schemers: In Dybvig, he > > states that the define form: > > > > (define square (lambda (x) (* x x))) > > > > is to be preferred to > > > > (define (square x) (* x x)) > > > > After reading that, I started using the first form religiously. Now > > I'm not so sure. For no small part because the text editor I use > > (TextMate) doesn't highlight the first form as a function definition > > but does highlight the second form. > > > > > The second form. > Shorter is better. > Always, always, always.
For pure chicken code this maybe correct. But some Scheme implementations happen to treat the former form as a global variable, which can be set! later on, while the latter is beeing compiled into a static binding and set! on it will raise an error. _______________________________________________ Chicken-users mailing list [email protected] http://lists.nongnu.org/mailman/listinfo/chicken-users
