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

From: Eli Zaretskii <[email-masked]>
Date: Fri, 12 Jan 2018 23:04:56 +0200

> From: Michael Heerdegen <[email-masked]>
> Cc: Stefan Monnier <[email-masked]>,  [email-masked]
> Date: Fri, 12 Jan 2018 21:55:25 +0100
> 
> What are we doing with scratch?
> 
> (1) Setting global variables, defining small functions and such simple
> stuff.  lexical-binding doesn't make a big difference here.

We need to discuss the differences whether they are big or not.

> (2) Re-evaluate parts of the source code, often with small
> modifications, for testing and debugging.  Since more and more packages
> make active use of lexical-binding, this is actually broken currently!
> Re-evaluating parts of source code in scratch can currently break Emacs.

You are describing a mistake.  People make mistakes all the time, and
will continue making mistakes whatever we do.  That shouldn't be a
basis for our decisions.

> (3) I often posted some code examples in emacs-help which made use of
> lexical-binding.  People pasted it into scratch and it didn't work.
> It's currently even not trivial to evaluate such examples with
> lexical-binding on.

Another mistake.  I don't see why this should be of any importance for
the decision at hand.

> OTOH, there is not too much code that really relies on dynamical binding
> mode.  And very often, such code is just written in a bad style (missing
> `defvar's etc.).

That's your opinion.  I happen not to share it.

> In summary, I think the advantages clearly prevail.

I actually didn't yet see any advantages mentioned, and the above
aren't, IMO.  Lexical-binding is just a feature, albeit an important
one.  It doesn't have to be introduced into every possible corner of
Emacs, not without a good reason.