Re: Python syntax in Lisp and Scheme
Edi Weitz <edi@agharta.de > writes:
[color=blue]
> [Followup-To ignored because I don't read comp.lang.pytho n]
>
> On Thu, 09 Oct 2003 16:13:54 GMT, Alex Martelli <aleax@aleax.it > wrote:
>[color=green]
> > I think it's about a single namespace (Scheme, Python, Haskell, ...)
> > vs CLisp's dual namespaces. People get used pretty fast to having
> > every object (whether callable or not) "first-class" --
> > e.g. sendable as an argument without any need for stropping or the
> > like. To you, HOFs may feel like special cases needing special
> > syntax that toots horns and rings bells; to people used to passing
> > functions as arguments as a way of living, that's as syntactically
> > obtrusive as, say, O'CAML's mandate that you use +. and not plain +
> > when summing floats rather than ints[/color]
>
> In Common Lisp (not "CLisp", that's an implementation) functions /are/
> first-class and sendable as an argument "without any need for
> stropping or the like." What exactly are you talking about?[/color]
Read him.
He's talking about NAMESPACES. "namespace" occurs twice in his
paragraph, while "function" occurs only once, that should have given
you a hint.
Namely, he's saying that people used to write: (mapcar cadr '((a 1) (b 2)))
don't like having to write: (mapcar #'cadr '((a 1) (b 2))) in Common-Lisp.
[ Personnaly, I rather write it as: (mapcar (function cadr) '((a 1) (b 2)))
The less read macro the better I feel.]
--
__Pascal_Bourgu ignon__
Do not adjust your mind, there is a fault in reality.
Edi Weitz <edi@agharta.de > writes:
[color=blue]
> [Followup-To ignored because I don't read comp.lang.pytho n]
>
> On Thu, 09 Oct 2003 16:13:54 GMT, Alex Martelli <aleax@aleax.it > wrote:
>[color=green]
> > I think it's about a single namespace (Scheme, Python, Haskell, ...)
> > vs CLisp's dual namespaces. People get used pretty fast to having
> > every object (whether callable or not) "first-class" --
> > e.g. sendable as an argument without any need for stropping or the
> > like. To you, HOFs may feel like special cases needing special
> > syntax that toots horns and rings bells; to people used to passing
> > functions as arguments as a way of living, that's as syntactically
> > obtrusive as, say, O'CAML's mandate that you use +. and not plain +
> > when summing floats rather than ints[/color]
>
> In Common Lisp (not "CLisp", that's an implementation) functions /are/
> first-class and sendable as an argument "without any need for
> stropping or the like." What exactly are you talking about?[/color]
Read him.
He's talking about NAMESPACES. "namespace" occurs twice in his
paragraph, while "function" occurs only once, that should have given
you a hint.
Namely, he's saying that people used to write: (mapcar cadr '((a 1) (b 2)))
don't like having to write: (mapcar #'cadr '((a 1) (b 2))) in Common-Lisp.
[ Personnaly, I rather write it as: (mapcar (function cadr) '((a 1) (b 2)))
The less read macro the better I feel.]
--
__Pascal_Bourgu ignon__
Do not adjust your mind, there is a fault in reality.
Comment