[Top][All Lists]

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

Re: lexical and dynamic binding

From: Ikumi Keita
Subject: Re: lexical and dynamic binding
Date: Thu, 28 Oct 2021 15:35:28 +0900

>>>>> Ikumi Keita <> writes:
> My understanding of the last sentence is as follows:
More straightforwad example is:
(setq foo 1) ; dynamic global binding without defvar.
(let ((foo foo)) ; creates lexical binding on foo.
  (setq foo (1+ foo)) ; sets lexically bound value.
  (symbol-value 'foo)) ; accesses dynamically bound value.
  ; => 1
This is the meaning of
| Note that if ‘lexical-binding’ is in effect, this returns the
| global value outside of any lexical scope.
, I think.

Ikumi Keita

reply via email to

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