bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#8304: 23.2; ad-read-advised-function default to func at point


From: Stefan Monnier
Subject: bug#8304: 23.2; ad-read-advised-function default to func at point
Date: Mon, 21 Mar 2011 10:40:38 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

>       * emacs-lisp/advice.el (ad-read-advised-function): Use
>       `function-called-at-point' as the default default, if the func at
>       point has advice, and passes PREDICATE.

Sounds like a fine change.

> -plays the same role as for `try-completion' (which see).  DEFAULT will
> -be returned on empty input (defaults to the first advised function for
> -which PREDICATE returns non-nil)."
> +plays the same role as for `try-completion' (which see).
> +
> +DEFAULT is returned on empty input.  DEFAULT defaults to the
> +function name at point if it's advised and passes PREDICATE,
> +otherwise to the first advised function which passes PREDICATE."

Actually, I don't think the docstring should document what `default' will
default to.  Actually, AFAICT the `default' argument is never used.

> +         ;; prefer func name at point, if it's in ad-advised-functions etc

Comments should start with a capital and end with a "." or some other
appropriate punctuation.


        Stefan





reply via email to

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