emacs-devel
[Top][All Lists]
Advanced

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

Re: org-crypt bug and other org inconveniences.


From: Stefan Monnier
Subject: Re: org-crypt bug and other org inconveniences.
Date: Wed, 20 Nov 2013 08:44:16 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

>> Note that this warning is not necessarily a problem.  Actually, I tend
>> to think we should just get rid of this warning (which I added, a few
>> years ago).
> Yes, setting a var locally already let-bounded works actually.
> But it is not what the documentation say.

> ,----
> | Making a variable buffer-local within a `let'-binding for that
> | variable does not work reliably, unless the buffer in which you do
> | this is not current either on entry to or exit from the `let'.
> | This is because `let' does not distinguish between different kinds
> | of bindings; it knows only which variable the binding was made for.
> `----

The documentation is indeed rather conservative.  But it is true that
over the years many bugs were found in this area (and fixed).
AFAIK there are no remaining bugs in this area (no proof of it, but
I did try to consider "all possible cases"), *but* the "right behavior"
in some cases is not always completely well-defined.  E.g.:

    <...global value of x = 1...>
    (let ((x 2))
      (make-local-variable 'x))

After this code (default-value 'x) should have value 1.
But what about the buffer-local value of x?

So the above comment basically tries to scare coders away from mixing
let-bindings and buffer-local bindings, because "there be dragons".

>> BTW, why not try to push Helm's support for Org to Org, i.e. make Org
>> support Helm, rather than the other way around?
> Sure, but I don't think org developers want to maintain/develop code
> depending on external applications.
> Emacs developers too I think, (AFAIK sending a patch to emacs handling
> external dependencies have been always refused).

If the interface is sufficiently clean and generic, I'd definitely
consider it.  Can't speak for Org people.


        Stefan


PS: Last time we talked about including Helm in GNU ELPA, there were
issues about copyright, IIRC.  If those issues are mostly in the various
mode-specific support files, we could focus on integrating the
infrastructure part of Helm separately.



reply via email to

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