Re: :method-invocation-order :depth-first

Jan Moringen <[email protected]> Sun, 18 Jul 2010 15:45:58 +0200
Newsgroups gmane.emacs.eieio
Message-ID <29970_1279460759_ZZh045a45ozyO.00_1279460758.2384.11.camel@steed.robot-madness>
Hi Frank.

> Is the :method-invocation-order :depth-first a common lisp feature?

There is no equivalent feature in Common Lisp. However, many modern CLOS
implementations in various Common Lisps are based on a Meta Object
Protocol [1]. This is a much more powerful mechanism to change the
behavior of the object system. For the method invocation order, which is
derived from the class precedence list (also in EIEIO), one would create
a new class meta object (the class of class objects) and write a custom
method that computes the class precedence list differently.

> Just curious as I'd like to know how portable this feature is;

As Eric explained, the :method-invocation-order option is specific to
EIEIO. The MOP is not part of Common Lisp, so it can be considered
non-standard as well. In practice however, Common Lisp programs using
the MOP can be written to be rather portable.

Kind regards,
Jan

[1] http://en.wikipedia.org/wiki/AMOP


------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first