GNU bug report logs - #3984
23.0.96; defadvice of call-interactively defeats interactive-p

Previous Next

Package: emacs;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Thu, 30 Jul 2009 22:45:04 UTC

Severity: minor

Done: Stefan Monnier <monnier <at> iro.umontreal.ca>

Bug is archived. No further changes may be made.

Full log


Message #105 received at 3984 <at> debbugs.gnu.org (full text, mbox):

From: Ryan <rct <at> thompsonclan.org>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>
Cc: 3984 <at> debbugs.gnu.org
Subject: Re: bug#3984
Date: Thu, 19 Sep 2013 01:06:03 -0700
Ok, I'll work on debugging my test case tomorrow.

On Wed Sep 18 20:38:48 2013, Stefan Monnier wrote:
>> advice.  This is what "advice--called-interactively-skip" does.  (Although
>> reading through it I don't see where the bug is that prevents it recognizing
>> the before advice in my example.)
>
> Exactly.  I think we need to fix this problem.  It really should work.
>
>> If all advised functions are wrapped by a call to the above function
>> "wrap-function-in-indicator-lambda",
>
> All functions advised with a non-:around advice have such
> a "recognizable wrapper"; and that's indeed what
> advice--called-interactively-skip checks in
>
>            (and (eq (nth 1 frame2) 'apply)
>                 (progn
>                   (funcall get-next-frame)
>                   (advice--p (indirect-function (nth 1 frame2)))))
>
> IOW the nadvice.el machinery is itself the recognizable wrapper.
> Not sure why this fails in your test case, tho.
>
> For :around advices, the machinery does not provide a recognizable
> wrapper, so we might want to add an ad-hoc wrapper like you suggest for
> those cases, tho maybe we can avoid the cost of such a wrapper, by
> keeping the so-advised inner-functions in a hash-table (so we can still
> recognize them, even tho they're not tagged directly in the backtrace).
>
> So, I think the first thing is to figure out why your test case fails.
>
>
>          Stefan




This bug report was last modified 11 years and 243 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.