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

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

bug#66908: Exposing more public nadvice API


From: Stefan Monnier
Subject: bug#66908: Exposing more public nadvice API
Date: Fri, 03 Nov 2023 18:05:40 -0400
User-agent: Gnus/5.13 (Gnus v5.13)

>> It's clearly the internal function most frequently used outside of
>> `nadvice.el`, indeed.
>> I think it'd be OK to promote that function to a non-internal name.
> It would be nice if you could since it would also provide some guarantee
> of it being a fairly stable interface.

Could you describe the circumstance where you need it?

> The other function that I saw get usage outside of nadvice and bytecomp
> was advice--symbol-function.  Should we use its return value, or is
> indirect-function's return value good enough for advice--cd*r?  IIRC,
> help-function-arglist uses indirect-function and it also works for our
> use case.

I don't think `advice--symbol-function` is a good candidate because its
semantics is not very clearly defined.  E.g. I'd be hard pressed to give
a comprehensible documentation of it without either being too vague,
or promising things I can't always provide, or getting too much into the
the nitty gritty details of the various possible situations.
That's why I haven't promoted the comment in its body
to an actual docstring :-(

Most callers are in only one of the many different situations, in which
case they usually don't need that functionality.


        Stefan






reply via email to

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