emacs-devel
[Top][All Lists]
Advanced

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

Re: User interaction from multiple threads


From: Eli Zaretskii
Subject: Re: User interaction from multiple threads
Date: Sat, 01 Sep 2018 10:00:38 +0300

> From: Gemini Lasswell <address@hidden>
> Cc: Eli Zaretskii <address@hidden>,  address@hidden,  address@hidden
> Date: Fri, 31 Aug 2018 14:37:44 -0700
> 
> I'm still developing my understanding of all this as well, and one
> important point that wasn't obvious to me at first is that each thread
> has its own special binding stack.  This is the m_specpdl field of
> thread_state, and is described a bit in lisp.h.  In addition to
> unwind-protects and the Lisp backtrace, it keeps track of
> dynamically-bound variables, the values of which are local to each
> thread.
> 
> The implication of this for the scenario of having a non-main thread ask
> the main thread to prompt on its behalf is that not just buffer-local
> variables but other global variables, and anything cl-letf can bind
> (including function definitions) would have to be communicated between
> the threads.

Indeed, and that makes this proposal a very complicated one at best.



reply via email to

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