[Top][All Lists]

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

RE: Should mode commands be idempotent?

From: Drew Adams
Subject: RE: Should mode commands be idempotent?
Date: Mon, 25 Sep 2017 06:57:07 -0700 (PDT)

> > That Emacs chooses to have its distributed modes be idempotent
> > is one thing.  That some 3rd-party code might also mistakenly
> > (unintentionally) prove to be non-idempotent is another, but
> > similar thing.  Such cases represent things to fix.
> >
> > That is different from establishing a convention that
> > modes should never, intentionally or unintentionally,
> > be non-idempotent.
> Yes, of course; you asked whether non-idempotence had
> ever been an issue for anyone; I gave you one example :)

Yes.  Thanks.

FWIW, I did notice it the first time you mentioned it.
And I guessed that in the `visual-line-mode' case the
non-idempotence is not intentional or necessary.  And I
agreed with RMS that Emacs can (obviously) fix such bugs.  

My questions in this thread have to do with the
usefulness of adding a rule/convention that affects
_user_ code.  (I've seen some users blindly quote some
rules as catechism, without much nuance or understanding
what's involved.)

I'm in favor of good conventions that are explained well.
I'm not yet convinced that what is being talked about
here is a good user convention.

If we do add a (user-targeted) rule for this, it should
be made clear for users (1) what the motivation is and
(2) just what we intend by "idempotence".

reply via email to

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