Python syntax in Lisp and Scheme
Andreas Rossberg
rossberg at ps.uni-sb.de
Thu Oct 9 08:00:12 EDT 2003
Dirk Thierbach wrote:
>
>>>you can use macros to do everything one could use HOFs for (if you
>>>really want).
>
> I should have added: As long as it should execute at compile time, of
> course.
>
>>Really? What about arbitrary recursion?
>
> I don't see the problem. Maybe you have an example? I am sure the
> Lisp'ers here can come up with a macro solution for it.
I'm not terribly familiar with the details of Lisp macros but since
recursion can easily lead to non-termination you certainly need tight
restrictions on recursion among macros in order to ensure termination of
macro substitution, don't you? Or at least some ad-hoc depth limitation.
- Andreas
--
Andreas Rossberg, rossberg at ps.uni-sb.de
"Computer games don't affect kids; I mean if Pac Man affected us
as kids, we would all be running around in darkened rooms, munching
magic pills, and listening to repetitive electronic music."
- Kristian Wilson, Nintendo Inc.
More information about the Python-list
mailing list