GNU bug report logs - #21365
Edebug always stops when execution enters an instrumented function

Previous Next

Package: emacs;

Reported by: Paul Pogonyshev <pogonyshev <at> gmail.com>

Date: Thu, 27 Aug 2015 20:04:02 UTC

Severity: wishlist

Done: Alan Mackenzie <acm <at> muc.de>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 21365 in the body.
You can then email your comments to 21365 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#21365; Package emacs. (Thu, 27 Aug 2015 20:04:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Paul Pogonyshev <pogonyshev <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Thu, 27 Aug 2015 20:04:02 GMT) Full text and rfc822 format available.

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

From: Paul Pogonyshev <pogonyshev <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Edebug always stops when execution enters an instrumented function
Date: Thu, 27 Aug 2015 22:03:12 +0200
[Message part 1 (text/plain, inline)]
This more of a feature request: make edebug stop when entering such a
function _optionally_.

Usecase: I want to debug certain function, but only when it takes specific
execution route. I instrument the function, set a breakpoint where I want
to debug it. But in addition to the breakpoint, edebug also pauses each
time the function is entered and I see no way to disable it.

In some cases this is a mere annoyance, in others it makes debugging
impossible. For example, currently I want to debug 'auto-revert-handler'
which somehow reverts buffer where both Auto Revert and Auto Revert Tail
modes are disabled. However, I can never make Edebug stop on

    (message "Reverting buffer `%s'." (buffer-name)))

line (though I see it _is_ executed, if only from the *Messages* buffer).
It always stops at the beginning of the function instead.

Paul
[Message part 2 (text/html, inline)]

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#21365; Package emacs. (Tue, 01 Sep 2015 10:06:02 GMT) Full text and rfc822 format available.

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

From: Alexis <flexibeast <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: Re: bug#21365: Edebug always stops when execution enters an
 instrumented function
Date: Tue, 01 Sep 2015 20:05:03 +1000
Paul Pogonyshev <pogonyshev <at> gmail.com> writes:

> This more of a feature request: make edebug stop when entering 
> such a function _optionally_.
>
> Usecase: I want to debug certain function, but only when it 
> takes specific execution route. I instrument the function, set a 
> breakpoint where I want to debug it. But in addition to the 
> breakpoint, edebug also pauses each time the function is entered 
> and I see no way to disable it.

Perhaps i'm misunderstanding you, but is setting the value of 
`edebug-initial-mode` what you're after?

https://www.gnu.org/software/emacs/manual/html_node/elisp/Edebug-Options.html#Edebug-Options

What happens if you set the value of that variable to 'go?


Alexis.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#21365; Package emacs. (Sun, 20 Sep 2015 22:32:01 GMT) Full text and rfc822 format available.

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

From: Alan Mackenzie <acm <at> muc.de>
To: 21365 <at> debbugs.gnu.org
Cc: Paul Pogonyshev <pogonyshev <at> gmail.com>
Subject: Re: bug#21365: Edebug always stops when execution enters an
 instrumented function
Date: 20 Sep 2015 22:31:47 -0000
Hello, Paul.

In article <mailman.28.1440705848.19560.bug-gnu-emacs <at> gnu.org> you wrote:
> [-- text/plain, encoding 7bit, charset: UTF-8, 20 lines --]

> This more of a feature request: make edebug stop when entering such a
> function _optionally_.

> Usecase: I want to debug certain function, but only when it takes specific
> execution route. I instrument the function, set a breakpoint where I want
> to debug it. But in addition to the breakpoint, edebug also pauses each
> time the function is entered and I see no way to disable it.

> In some cases this is a mere annoyance, in others it makes debugging
> impossible. For example, currently I want to debug 'auto-revert-handler'
> which somehow reverts buffer where both Auto Revert and Auto Revert Tail
> modes are disabled. However, I can never make Edebug stop on

>     (message "Reverting buffer `%s'." (buffer-name)))

> line (though I see it _is_ executed, if only from the *Messages* buffer).
> It always stops at the beginning of the function instead.

Yes, I sometimes feel this annoyance too.

Looking at the source code in edebug.el, it seems this problem was sensed
by Eric Raymond, and he was working on it in May 1992.  (!!!!)  The
function `edebug-set-initial-mode' was commented out by edebug's original
author Daniel LaLiberte on 24th March 1994.  21 years later, the reasons
for this commenting out have probably been lost.  (Takes hat off to git
blame.)

I don't see any overwhelming reasons why ESR's idea and code couldn't be
resurrected.

> Paul

-- 
Alan Mackenzie (Nuremberg, Germany).





Reply sent to Alan Mackenzie <acm <at> muc.de>:
You have taken responsibility. (Tue, 22 Sep 2015 12:57:03 GMT) Full text and rfc822 format available.

Notification sent to Paul Pogonyshev <pogonyshev <at> gmail.com>:
bug acknowledged by developer. (Tue, 22 Sep 2015 12:57:04 GMT) Full text and rfc822 format available.

Message #16 received at 21365-done <at> debbugs.gnu.org (full text, mbox):

From: Alan Mackenzie <acm <at> muc.de>
To: 21365-done <at> debbugs.gnu.org
Cc: Paul Pogonyshev <pogonyshev <at> gmail.com>
Subject: Re: bug#21365: Edebug always stops when execution enters an
 instrumented	function
Date: 22 Sep 2015 12:56:48 -0000
> This more of a feature request: make edebug stop when entering such a
> function _optionally_.

Fixed by amending the documentation in edebug.texi in master.

-- 
Alan Mackenzie (Nuremberg, Germany).





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 21 Oct 2015 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 9 years and 245 days ago.

Previous Next


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