Go to the first, previous, next, last section, table of contents.


Advising Emacs Lisp Functions

The advice feature lets you add to the existing definition of a function, by advising the function. This is a clean method for a library to customize functions defined by other parts of Emacs--cleaner than redefining the whole function.

Each function can have multiple pieces of advice, separately defined. Each defined piece of advice can be enabled or disabled explicitly. The enabled pieces of advice for any given function actually take effect when you activate advice for that function, or when that function is subsequently defined or redefined.

Usage Note: Advice is useful for altering the behavior of existing calls to an existing function. If you want the new behavior for new calls, or for key bindings, it is cleaner to define a new function (or a new command) which uses the existing function.


Go to the first, previous, next, last section, table of contents.