emacs-devel
[Top][All Lists]
Advanced

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

Re: Multiple major modes


From: Richard Stallman
Subject: Re: Multiple major modes
Date: Sun, 01 Jul 2007 16:40:13 -0400

    The function overload mechanism is also a feature I use in semantic.
    Most features that work in multiple major modes today provide a
    variable where you can put a symbol that is a function that would then
    provide some mode-specific functionality.

    My semantic tool has hundreds of these functions, so I abstracted the
    concept up so that the implementations could be declarative, instead
    of programmatic. 

I really don't like the idea of function overloads.  This mechanism
shares the drawbacks of advice: that a function doesn't do what its
definition says.

                      It also makes it easy to make most functions
    overridable, which helps avoid forcing users to use advice when
    customizing my tool.

It is easy to replace advising with another similar mechanism,
but it doesn't solve the problem.

It seems to me that there is no need for this.  Calling a variable
with funcall should do the same job.  That way, the call _shows_
that the function isn't fixed.




reply via email to

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