From: Eli Zaretskii <eliz@gnu.org>
To: Drew Adams <drew.adams@oracle.com>
Cc: raimon@konghq.com, 31671@debbugs.gnu.org
Subject: bug#31671: 26.1; edebug-defun doesn't step if functions run in a separate thread
Date: Tue, 05 Jun 2018 17:47:52 +0300 [thread overview]
Message-ID: <83602xb887.fsf@gnu.org> (raw)
In-Reply-To: <b6ac5457-5353-4a73-9835-2c131d08398f@default> (message from Drew Adams on Mon, 4 Jun 2018 10:23:58 -0700 (PDT))
> Date: Mon, 4 Jun 2018 10:23:58 -0700 (PDT)
> From: Drew Adams <drew.adams@oracle.com>
> Cc: 31671@debbugs.gnu.org
>
> > The problem here is that Edebug enters recursive-editing (on the
> > non-main thread which runs the function 'foo'), then waits for the
> > user to press a key. While it waits, it releases the global lock, and
> > the main thread starts running. So when you press a key, you are on a
> > different thread, and 'throw' doesn't have a matching 'catch' (because
> > that 'catch' is stored with the handlers of the thread which runs
> > 'foo'.
> >
> > Not yet sure how to deal with this. Thoughts and ideas are welcome.
>
> Not really following this thread, and 100% unknowledgable
> about Emacs threading. But somewhat curious: Does the same
> problem exist for plain `debug' as for `edebug'?
Yes. Modify the recipe like this, and you have the same problem with
'debug':
emacs -Q
Type:
(defun foo ()
(message "Hi"))
Eval the function to define it.
M-x debug-on-entry RET foo RET
M-: (make-thread 'foo) RET
Type 'd' in the backtrace that Emacs presents.
next prev parent reply other threads:[~2018-06-05 14:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <<87muwfsp4i.fsf@konghq.com>
[not found] ` <<83r2lmbidf.fsf@gnu.org>
2018-06-04 17:23 ` bug#31671: 26.1; edebug-defun doesn't step if functions run in a separate thread Drew Adams
2018-06-05 14:47 ` Eli Zaretskii [this message]
2018-05-31 17:37 Raimon Grau
2018-06-04 16:56 ` Eli Zaretskii
2018-06-05 14:51 ` Eli Zaretskii
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=83602xb887.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=31671@debbugs.gnu.org \
--cc=drew.adams@oracle.com \
--cc=raimon@konghq.com \
/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.