emacs-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] (Updated) Run hook when variable is set


From: Stefan Monnier
Subject: Re: [PATCH] (Updated) Run hook when variable is set
Date: Thu, 19 Feb 2015 08:30:49 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

>> AFAICT this absurd concept comes from your interpretation of what's
>> going on, and just shows that your interpretation is not
>> a good model.
> Regardless of the name, the interpretation is the right one for
> multi-threaded code, and is just as valid as the alternative for
> single-threaded code.

No, the interpretation based on the current implementation (i.e. "void"
is just a special value) works just as well in the multithreaded case.

> Oh, I thought that was clear. Have makunbound signal an error if
> let_shadows_global_binding_p or Flocal_variable_p is true. My theory is that
> this would only catch bugs, not catch intentional uses.

Based on my experience with emitting messages in similar oddball cases
(i.e. making a variable buffer-local while it's globally let-bound), my
guess is that it would catch a few very rare oddball cases indeed, but:
1- those oddball cases end up harmless.
2- there's no easy "fix" for those cases (because the let-binding and the
   makunbound happen in completely unrelated code which usually aren't
   used at the same time and what *really* should happen is at best
   unclear, or is otherwise exactly what happens with the current
   semantics you don't like).

> Well, ⌜vetted⌝ works just as well as ⌜writable⌝ for the field name, so I'm
> inclined to leave it that way, but I'll change it if you want.

Can I have my bikeshed transparent?


        Stefan



reply via email to

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