[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: advice needed for multi-threading patch
From: |
Stefan Monnier |
Subject: |
Re: advice needed for multi-threading patch |
Date: |
Mon, 28 Sep 2009 20:27:14 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) |
> In my view, a let-binding should always be thread-local, and I think
> buffer-localness shouldn't affect this. This is enough of a rule to
> answer your questions -- but it is just one choice, we could make
> others, I suppose.
So what should happen in the following case:
Thread A, running in buffer B1, runs the following code:
(let ((default-directory "/foo"))
(with-current-buffer B2 default-directory))
You seem to say that it should return "/foo", but currently it returns
something else. Maybe we should try to come up with a run-time test to
catch such cases in current Lisp code. A related case is when a process
filter or a sentinel is run via accept-process-output: we'd need to be
careful to make sure the code is run in the same thread as the code that
called accept-process-output.
> There are some oddities implied by making buffer-local let-bindings
> also be thread-specific. For example, some buffer-locals affect
> redisplay, so what the user sees will depend on the thread in which
> redisplay is run.
Redisplay should be run in a completely separate thread (at least
conceptually).
Stefan
- Re: advice needed for multi-threading patch, (continued)
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/22
- Re: advice needed for multi-threading patch, Stefan Monnier, 2009/09/24
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/24
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/27
- Re: advice needed for multi-threading patch, Stefan Monnier, 2009/09/27
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/28
- Re: advice needed for multi-threading patch,
Stefan Monnier <=
- Re: advice needed for multi-threading patch, Ken Raeburn, 2009/09/28
- Re: advice needed for multi-threading patch, Stefan Monnier, 2009/09/28
- Re: advice needed for multi-threading patch, Ken Raeburn, 2009/09/28
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/28
- Re: advice needed for multi-threading patch, Ken Raeburn, 2009/09/29
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/28
- Re: advice needed for multi-threading patch, Giuseppe Scrivano, 2009/09/23
- Re: advice needed for multi-threading patch, Stefan Monnier, 2009/09/24
- Re: advice needed for multi-threading patch, Giuseppe Scrivano, 2009/09/24
- Re: advice needed for multi-threading patch, Tom Tromey, 2009/09/24