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

Re: specializer-direct-xxx generic functions



    Date: Thu, 4 Oct 1990 00:01 EDT
    From:	Gregor Kiczales <Gregor@parc.xerox.com>


    Mumble, the interaction between generic-flet/labels, the metaobject
    protocol, weak pointers and finalization is certainly one of the least
    well worked out parts of the Metaobject Protocol.  Issues like these
    are going to need a lot of work in the next few years as we figure how
    to expand the MOP ideas.

    But I am not sure what you are proposing.  SPECIALIZER-DIRECT-METHODS
    isn't in 88-002R as it is.  Implementors who do MOP stuff can either put
    it in or not.  Personally, I would do so, even if it meant not
    implementing generic-flet.  Alternatively, I might do it by having the
    methods generated by generic-flet not get recorded.

Another possibility that could be explored would be for
generic-flet/-labels/-function to have two kinds of metaobjects: for want of
a better name I'll call them template-generic-function/template-method, and
closure-generic-function/closure-method.  A generic-flet form would create
the template metaobjects once when the form is processed, and would create a
new set of closure metaobjects each time it is executed.  The analogy is
intended to be to compiled functions and closures of compiled functions.
SPECIALIZER-DIRECT-METHODS then would return the template-methods.  This way
the set of objects to be returned by SPECIALIZER-DIRECT-METHODS would be
poroprtional to the static size of the program rather than to the dynamic
size of the program's execution.  This is an old Scott Cyphers idea that has
not been adequately worked out; I wouldn't guarantee that it will turn out
to work, but it's a possibility.