Timothy <orgm...@tec.tecosaur.net> writes: >> I do not think that setting `lexical-binding’ file-local variable in an >> Org file makes much sense. I am sure that we can do better. > > I suppose part of the question is what sort of way we treat it? In my mind, > considering the current way lexical scope is seen in Emacs (used everywhere in > modern elisp, not on-by-default because that would break compat, is my > impression). I think it would make sense if this eventually ends up with a > “globally enabled everywhere by default” setting, which is why I think a > defcustom may be the best fit.
Do you mean to enable :lexical t in all the elisp source blocks? It is already possible (and done) using `org-babel-default-header-args:emacs-lisp'. -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at <https://orgmode.org/>. Support Org development at <https://liberapay.com/org-mode>, or support my work at <https://liberapay.com/yantar92>