emacs-devel
[Top][All Lists]
Advanced

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

Re: EIEIO


From: David Engster
Subject: Re: EIEIO
Date: Fri, 14 Mar 2014 07:42:04 +0100
User-agent: Gnus/5.13001 (Ma Gnus v0.10) Emacs/24.3 (gnu/linux)

Daniel Colascione writes:
> A while ago, I considered using EIEIO for one of my projects; I decided
> to use plain defstructs instead. I didn't like how EIEIO required each
> object to have a name (requiring that EIEIO allocate a new string for
> each object instance), and I had very simple interface requirements, and
> found calling funcall on a struct slot more straightforward than a
> generic function.

For simple projects, I don't use EIEIO either. However, from my
experience, the defstruct/funcall thing soon becomes tedious and
confusing on bigger projects. I think the main problem is that those
things aren't "self-documenting", which makes understanding and
maintaining such a code base difficult. In EIEIO, you can provide
documentation for pretty much anything, and it is integrated in Emacs'
help system[1], allowing you to jump to the different implementations of
a method. I find this to be a big advantage, well worth the initial
learning time.

-David

[1] At least this was the case for EIEIO in CEDET upstream, where we did
this through defadvice. Unfortunately, it took until a few weeks ago to
properly integrate this in Emacs proper.



reply via email to

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