emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: interactive closure — variables not bound


From: Ricardo Wurmus
Subject: Re: interactive closure — variables not bound
Date: Thu, 29 Sep 2016 11:09:22 +0200
User-agent: mu4e 0.9.16; emacs 25.1.1

Stefan Monnier <address@hidden> 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 via email to

[Prev in Thread] Current Thread [Next in Thread]