[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: User-reserved element in byte code vectors
From: |
Miles Bader |
Subject: |
Re: User-reserved element in byte code vectors |
Date: |
18 May 2004 10:29:39 +0900 |
David Kastrup <address@hidden> writes:
> Without lexical binding, currying a curried function would probably
> not work when using the lambda approach (haven't thought this through
> in detail, though).
It should, I'd think -- the method suggested for using lambda to do it
is to construct a lambda expression at runtime, e.g.,
(defun curry (fun &rest args)
`(lambda (&rest user-args) (apply #',fun ,@args user-args)))
So currying a curried function does work, if rather `consily':
(curry (curry 'concat "a" "b") "x" "y")
=> (lambda (&rest user-args)
(apply (function
(lambda (&rest user-args)
(apply (function concat) "a" "b" user-args)))
"x" "y" user-args))
(mapcar (curry (curry 'concat "a" "b") "x" "y") '("p" "q"))
=> ("abxyp" "abxyq")
-Miles
--
"Whatever you do will be insignificant, but it is very important that
you do it." Mahatma Gandhi
- Re: User-reserved element in byte code vectors, (continued)
- Re: User-reserved element in byte code vectors, Richard Stallman, 2004/05/15
- Re: User-reserved element in byte code vectors, Miles Bader, 2004/05/15
- Re: User-reserved element in byte code vectors, Richard Stallman, 2004/05/17
- Re: User-reserved element in byte code vectors, Lars Brinkhoff, 2004/05/17
- Re: User-reserved element in byte code vectors, Stefan Monnier, 2004/05/17
- Re: User-reserved element in byte code vectors, Miles Bader, 2004/05/17
- Re: User-reserved element in byte code vectors, David Kastrup, 2004/05/17
- Re: User-reserved element in byte code vectors,
Miles Bader <=
- Re: User-reserved element in byte code vectors, Richard Stallman, 2004/05/18
- Re: User-reserved element in byte code vectors, Miles Bader, 2004/05/18
- Re: User-reserved element in byte code vectors, Stefan Monnier, 2004/05/18
- Re: User-reserved element in byte code vectors, Miles Bader, 2004/05/18
- Re: User-reserved element in byte code vectors, David Kastrup, 2004/05/19
- Re: User-reserved element in byte code vectors, Miles Bader, 2004/05/19
- Re: User-reserved element in byte code vectors, Richard Stallman, 2004/05/19
- Function vectors: +funvec-20030520-0-c.patch, Miles Bader, 2004/05/19
- Re: User-reserved element in byte code vectors, Kim F. Storm, 2004/05/19
- Re: User-reserved element in byte code vectors, Richard Stallman, 2004/05/19