[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#59820: [PATCH] * nadvice/nadvice.el: support non-symbol (closure/lam
From: |
Stefan Kangas |
Subject: |
bug#59820: [PATCH] * nadvice/nadvice.el: support non-symbol (closure/lambda) advices (old Emacs) |
Date: |
Mon, 9 Oct 2023 09:45:20 +0000 |
tags 59820 + patch
thanks
Daan Ro <daanturo@gmail.com> writes:
> Use `warn` instead of `message`.
Stefan, what do you think? Should the below patch be installed?
> From f30a1f6d815a038dde51ea09089e9aa2155c8c62 Mon Sep 17 00:00:00 2001
> From: Daanturo <daanturo@gmail.com>
> Date: Tue, 13 Dec 2022 21:28:03 +0700
> Subject: [PATCH] * nadvice/nadvice.el: warn against non-symbol FUNCTIONs
>
> ---
> nadvice.el | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/nadvice.el b/nadvice.el
> index 443a5d0..c6666d0 100644
> --- a/nadvice.el
> +++ b/nadvice.el
> @@ -57,6 +57,8 @@
> (if (symbolp func)
> func
> (let* ((sym (intern (format "%S" func))))
> + (warn "This version of nadvice.el recommends that \
> +FUNCTION: %S is a named symbol instead." func)
> (unless (fboundp sym)
> (defalias sym func))
> sym)))
> --
> 2.39.0
- bug#59820: [PATCH] * nadvice/nadvice.el: support non-symbol (closure/lambda) advices (old Emacs),
Stefan Kangas <=