[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Me no understand scoping

From: Maciek Godek
Subject: Re: Me no understand scoping
Date: Wed, 30 Jul 2008 10:42:47 +0200

Clinton Ebadi:

> `macroexpand-1' is helpful here -- (local-eval ,f env) is wrong.
> As a matter of style, you probably want to avoid local-eval as it will
> have to be removed whenever Guile ends up with a faster compiler

On the other hand, local-eval is explained in guile manual,
while I couldn't find any documentation for guile's macroexpand-1,
nor for scheme macroexpand-1 (there are some explanations available
for the lisp language). So it's probably equally evil ;]

> (one day when guile-vm is integrated into core and lexical environments
> become fixed arrays or similar), and messing with existing lexical
> environments is Very Bad (tm). Avoiding all uses of eval and, by
> extension, local-eval is a good idea.

as for eval, it will always be there (in RnRS)
besides I don't imagine not messing with lexical
environments :) The bad thing is that scopes aren't
explicitly definable and the report doesn't say
much about their properties. I don't know how
about practical performance, but I'd find it best
if they were implemented as (implicit) hash tables
that could be bound to variables and passed as
arguments. I think that they could perform
equally good as fixed arrays for memoized


reply via email to

[Prev in Thread] Current Thread [Next in Thread]