emacs-devel
[Top][All Lists]
Advanced

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

Re: Emacs Lisp and Guile


From: Richard Stallman
Subject: Re: Emacs Lisp and Guile
Date: Tue, 20 Aug 2002 18:12:06 -0600 (MDT)

    Yes, we could do that.  We could also try to generalize the fluids so
    that they can be 'local' to other contexts besides threads, like
    buffers or frames.

That would be much more inconvenient to use, so it is not a good idea.
Let's make these variables accessible simply *as variables*.

    > This needs to be done for all variables, since any might perhaps be
    > made buffer-local.  fluid-let could expand into the proper code for
    > this.

    We should probably tackle this as the larger, more general problem of
    working with arbitrary 'contexts' and variable-like 'entities'
    (variables, or fluids, or settable functions, or...) that can take on
    context-local values.  Let's call these entities "locations".

I think it is better if we do not generalize that far.  That extra
generalization makes things much more complicated and gives little
extra power.

I think we should start by handling just variables, and see how
convenient we can make that limited feature,

    The values of locations could be (conceptually) stored in a data base
    that is indexed with keys that are the combination of a location and
    another arbitrary value.

That is possible but it would make things much slower.  It makes no
sense to consider such a big slowdown for an unimportant
generalization.  The speed is more important than the extra
generality.  So this is not a good idea at all.

    'Setting' a location LOC to the value VAL goes like this: when the
    context reference is #f, store VAL with the key (LOC . #f).  When the
    reference is not #f, 'get' the value CTXT of the referenced location
    and store VAL with the key (LOC . CTXT).

This is totally unnatural for variables.  We want the ordinary Scheme
value of the variable `foo' to be the proper value from whichever
binding is current, even when `foo' has buffer-local bindings.

Please focus on implementing this feature for variables in the most
natural and efficient way you can.






reply via email to

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