From: Ryan <rct@thompsonclan.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: 3984@debbugs.gnu.org
Subject: bug#3984:
Date: Thu, 19 Sep 2013 12:23:58 -0700 [thread overview]
Message-ID: <523B4F4E.3060204@thompsonclan.org> (raw)
In-Reply-To: <523AB06B.9090606@thompsonclan.org>
On a related note, I just noticed that the
"advice-test-called-interactively-p" test in
test/automated/advice-tests.el happens to pass, but only because it
doesn't use "called-interactively-p" inside the original function, but
rather only inside the advice itself. Also, it doesn't test advising
"call-interactively" itself. I think I will see about writing a proper
test first, and then use that to start debugging.
On Thu Sep 19 01:06:03 2013, Ryan wrote:
> 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
next prev parent reply other threads:[~2013-09-19 19:23 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-30 22:37 bug#3984: 23.0.96; defadvice of call-interactively defeats interactive-p Drew Adams
2009-07-31 1:58 ` Stefan Monnier
2009-07-31 14:19 ` Drew Adams
2009-07-31 19:31 ` Stefan Monnier
2009-07-31 20:04 ` Drew Adams
2011-10-10 6:00 ` Kai Tetzlaff
2011-10-11 14:26 ` Drew Adams
2011-10-11 15:46 ` Stefan Monnier
2011-10-11 16:05 ` Drew Adams
2013-09-10 20:29 ` Christopher Wellons
2013-09-11 0:29 ` Stefan Monnier
2013-09-13 8:56 ` bug#3984: Fix for #3984 Ryan
2013-09-13 13:18 ` Stefan Monnier
2013-09-13 18:30 ` Ryan
2013-09-13 19:27 ` Ryan
2013-09-13 21:02 ` Stefan Monnier
2013-09-17 3:18 ` Ryan
2013-09-17 13:10 ` Stefan Monnier
2013-09-17 17:22 ` bug#3984: Ryan
2013-09-18 1:46 ` bug#3984: Stefan Monnier
2013-09-18 23:30 ` bug#3984: Ryan
2013-09-19 0:47 ` bug#3984: Ryan
2013-09-19 3:38 ` bug#3984: Stefan Monnier
2013-09-19 8:06 ` bug#3984: Ryan
2013-09-19 19:23 ` Ryan [this message]
2013-09-19 20:59 ` bug#3984: Stefan Monnier
2013-09-19 21:59 ` bug#3984: Ryan
2013-09-20 4:23 ` bug#3984: Ryan
2013-09-20 4:58 ` bug#3984: Fix case where call-interactively is advised Ryan
2013-09-20 5:03 ` bug#3984: Ryan
2013-09-20 14:35 ` bug#3984: Stefan Monnier
2013-09-20 16:54 ` bug#3984: Ryan
2013-09-20 16:56 ` bug#3984: Ryan
2013-09-20 14:54 ` bug#3984: Stefan Monnier
2013-09-20 16:50 ` bug#3984: Ryan
2013-09-20 19:59 ` bug#3984: Stefan Monnier
2013-09-13 10:24 ` bug#3984: bug#123: Potential fix Ryan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=523B4F4E.3060204@thompsonclan.org \
--to=rct@thompsonclan.org \
--cc=3984@debbugs.gnu.org \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.