Commit e5446586 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

Clarify n-1, etc. in example.

parent 02f34c70
......@@ -684,10 +684,11 @@ specifies the argument list for the function @code{fset}.
@node Combined Definition
@section The Combined Definition
Suppose that a function has @var{n} pieces of before-advice, @var{m}
pieces of around-advice and @var{k} pieces of after-advice. Assuming no
piece of advice is protected, the combined definition produced to
implement the advice for a function looks like this:
Suppose that a function has @var{n} pieces of before-advice
(numbered from 0 through @var{n}@minus{}1), @var{m} pieces of
around-advice and @var{k} pieces of after-advice. Assuming no piece
of advice is protected, the combined definition produced to implement
the advice for a function looks like this:
@example
(lambda @var{arglist}
......@@ -695,20 +696,20 @@ implement the advice for a function looks like this:
(let (ad-return-value)
@r{before-0-body-form}...
....
@r{before-@var{n}-1-body-form}...
@r{before-@var{n}@minus{}1-body-form}...
@r{around-0-body-form}...
@r{around-1-body-form}...
....
@r{around-@var{m}-1-body-form}...
@r{around-@var{m}@minus{}1-body-form}...
(setq ad-return-value
@r{apply original definition to @var{arglist}})
@r{other-around-@var{m}-1-body-form}...
@r{end-of-around-@var{m}@minus{}1-body-form}...
....
@r{other-around-1-body-form}...
@r{other-around-0-body-form}...
@r{end-of-around-1-body-form}...
@r{end-of-around-0-body-form}...
@r{after-0-body-form}...
....
@r{after-@var{k}-1-body-form}...
@r{after-@var{k}@minus{}1-body-form}...
ad-return-value))
@end example
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment