[Top][All Lists]

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

Re: comint-carriage-motion causes severe problems.

From: Luc Teirlinck
Subject: Re: comint-carriage-motion causes severe problems.
Date: Thu, 4 Jul 2002 11:56:22 -0500 (CDT)

Dear Stefan,

My main concern with the 'override stuff was the danger of breaking
existing code and the danger of repeated loading having unwanted
effects.  If you checked out things carefully, then I guess it is not

This makes, of course, the other change a little bit more dangerous,
since its effect on existing code has not been tested yet.

Let me just tell you about my concern.  Through autoloads, :load and
:require keywords in defgroups and defcustoms and so on, plenty of
functions can be unpredictably added to the global values of hooks,
behind the user's back.  This actually happens all the time in
practice.  Just searching for some item using customize-browse can add
plenty of functions to hooks, even if no custumizations are actually
made.  Some of these functions may be globally necessary, but cause
trouble locally.  We may want to exclude them from the local value
before they appear in the global one because we have no idea when that
might happen.  

   After all

              (remove-hook 'foo 'bar)
              (add-hook 'foo 'bar)

      does not prevent `bar' from being run (the `remove-hook' above ends up
      being a noop).

This is not the same situation. We remove bar fom the global value
and add it right back.  Clearly that should be a no-op.

On the other hand:

(remove-hook 'foo 'bar 'local)
(add-hook 'foo 'bar)

first removes it from the local value and then adds it to the global.
This is not an inverse operation, as in the previous example, and
hence, there is no logical reason why it should be a no-op.

I will wait for your comments before making any additional



reply via email to

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