all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Ricardo Wurmus <rekado@elephly.net>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: interactive closure — variables not bound
Date: Thu, 29 Sep 2016 11:09:22 +0200	[thread overview]
Message-ID: <87bmz7t6mk.fsf@elephly.net> (raw)
In-Reply-To: <jwvr3834lnh.fsf-monnier+Inbox@gnu.org>


Stefan Monnier <monnier@iro.umontreal.ca> writes:

>> I guessed that this odd behaviour must be a result of calling the
>> callback procedure from C with “call1”.  I thought that maybe this is
>> expected behaviour when calling a procedure that interacts with the user
>> through the mini-buffer (as read-string does) when it is not using the
>> “interactive” form.
>
> read-string works just as well from outside an interactive spec.
>
> My crystal ball tells me that it suspects the culprit is that the code
> calls the Elisp callback asynchronously, i.e. from a different thread.
> IOW it thinks that the code doesn't bother to go through the Elisp event
> queue to synchronize with the Elisp engine.

Ah, this indeed seems to be the case here!  I wasn’t aware of the Elisp
event queue.  Now that I am, I see that xwidget.c already contains code
to create events of kind “XWIDGET_EVENT”, so I’ll try to use that.

Thanks for the good hint!

~~ Ricardo




      reply	other threads:[~2016-09-29  9:09 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-28  6:21 interactive closure — variables not bound Ricardo Wurmus
2016-09-28 12:41 ` Stefan Monnier
2016-09-28 21:12   ` Ricardo Wurmus
2016-09-29  0:07     ` Stefan Monnier
2016-09-29  9:09       ` Ricardo Wurmus [this message]

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=87bmz7t6mk.fsf@elephly.net \
    --to=rekado@elephly.net \
    --cc=emacs-devel@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.