Python syntax in Lisp and Scheme
james anderson
james.anderson at setf.de
Tue Oct 7 18:34:16 EDT 2003
Eli Barzilay wrote:
>
> james anderson <james.anderson at setf.de> writes:
>
> > Eli Barzilay wrote:
> > >
> > > (This hits one of the major differences between Lisp and Scheme --
> > > in Lisp I'm not as happy to use HOFs because of the different
> > > syntax
> >
> > which different [] syntax?
>
> Huh?
that is, what is different about the syntax for higher-order functions in lisp?
>
> > > (which is an indication of a different mindset, which leads to
> > > performance being optimized for a certain style). Scheme is much more
> > > functional in this respect, for example -- using HOF versions of
> > > with-... compared to Lisp where these are always macros.)
> >
> > in practice, as a rule, a with- is available at least optionally also as a
> > call-with-. not just for convenience, but also for maintainability.
> > [...]
>
> Yes, but I was talking about the difference approaches, for example:
>
> (dolist (x foo)
> (bar x))
>
> vs:
>
> (mapc #'bar foo)
are these not two examples of coding in common-lisp. how do they demonstrate
that "scheme is much more functional"?
>
> > i am curious, however, about the HOF equivalents for macros which
> > expand primarily to changes to the lexical environment. [...]
>
> That was the point I made in the beginning.
sorry, i missed that.
More information about the Python-list
mailing list