GNU bug report logs - #35351
27.0.50; Enable derived modes to run their own very-early 'change-major-mode-hook' code

Previous Next

Package: emacs;

Reported by: Phil Sainty <psainty <at> orcon.net.nz>

Date: Sun, 21 Apr 2019 02:41:01 UTC

Severity: wishlist

Found in version 27.0.50

Full log


View this message in rfc822 format

From: Richard Stallman <rms <at> gnu.org>
To: Phil Sainty <psainty <at> orcon.net.nz>
Cc: 35351 <at> debbugs.gnu.org
Subject: bug#35351: 27.0.50; Enable derived modes to run their own very-early 'change-major-mode-hook' code
Date: Sun, 21 Apr 2019 02:01:51 -0400
[[[ To any NSA and FBI agents reading my email: please consider    ]]]
[[[ whether defending the US Constitution against all enemies,     ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]

  > I forgot to mention the other hack solution which occurred to me,
  > which is for the library which defines the major mode to add its
  > own before-advice for that major mode function.

We have adopted the design principle that advice is for users to add,
and nothing else.

This is because developers investigating why a call to the function
foo doesn't work as expected will not think of the possibility that
foo has advice.

Thus, our design rule is that, if you want some code to be run before
or after calls to foo, add code to foo to run a hook.  This way, the
code for foo will show developers that a hook is called.
-- 
Dr Richard Stallman
President, Free Software Foundation (https://gnu.org, https://fsf.org)
Internet Hall-of-Famer (https://internethalloffame.org)






This bug report was last modified 6 years and 53 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.