Subject: bug#30078: 27.0.50; Use lexical-binding for M-:

From: Drew Adams <[email-masked]>
Date: Sat, 13 Jan 2018 18:07:13 -0800 (PST)

> lexbind-Elisp and dynbind-Elisp are fundamentally two different
> languages.

If you want to argue that then Lisp itself is fundamentally
several languages.  (Yes, even Lisp 1.5, sans CLOS and all
the rest.)

Nothing says that a single language cannot "fundamentally"
have more than one kind of binding/scoping.

> They are so similar that we don't think of it in those
> terms, but having those 2 introduces complexity (including for the users
> occasionally).  And actually the fact they're so similar sometimes makes
> the problem worse because most people don't realize that they have to
> pay attention to it or how to know which language is used when.

There are plenty of things that one needs to pay attention
to in Lisp.  List-structure, for one.  Lisp is not Haskell.
Yes, Lisp can be complex, for both users and implementors.

> I very much hope to see Emacs shed its dynbind-Elisp support at some
> point, tho it still seems to be a pretty distant future and I'm not even
> sure how we'll get to that point.

I very much hope _not_.

Lexical and dynamic binding each have their place in Lisp,
especially in Emacs Lisp.  RMS underlined the importance
of dynamic binding for Emacs.  That argument remains as
potent and relevant today as when he wrote it.

http://www.gnu.org/software/emacs/emacs-paper.html#SEC18

Lexical and dynamic binding have coexisted fine in Common
Lisp for almost 40 years now.

And lexical binding is the default in Common Lisp.  That
would be fine for Emacs Lisp too someday.  I have no
objection to a move toward that, in principle.

It was a definite plus to add lexical binding to Emacs.
Thank you very much for that.  Bravo.  (And a vacuous
`defvar' is not a bad way to declare a special/dynamic
variable.)

On the other hand, it would be a definite impairment to
remove dynamic binding from Emacs Lisp.  No thank you.

> bug#30078 is about making another step in this direction.

If that's all bug#30078 is about then don't do it.
(But I hope that's not all it's about.)