bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#66756: 30.0.50; [PATCH] Improve discussion of 'let' in Elisp Introdu


From: Richard Stallman
Subject: bug#66756: 30.0.50; [PATCH] Improve discussion of 'let' in Elisp Introduction manual
Date: Sun, 05 Nov 2023 21:29:30 -0500

[[[ To any NSA and FBI agents reading my email: please consider    ]]]
[[[ whether defending the US Constitution against all enemies,     ]]]
[[[ foreign or domestic, requires you to follow Snowden's example. ]]]

  > +The @code{let} special form provides a way to confine your variables
  > +to a particular section of your code (in computer science jargon, a
  > +``scope'').  @code{let} creates a name for a @dfn{local variable} that
  > +overshadows any use of the same name outside the @code{let} expression
  > +(we call this ``binding'' the variable).  This prevents any accidental
  > +usage of these variables outside of the @code{let} expression.

This is one of several reasons to use `let'.

Others are

* To compute a value once and use it more than once.

* To create a loop index variable.

* For special variables, to bind them si as to control the behavior
of other code.

Should all of them be mentioned in this node?  I am not sure;
that is a pedagogical question.  But this node shouldn't assert
that one reason is the only reason.


-- 
Dr Richard Stallman (https://stallman.org)
Chief GNUisance of the GNU Project (https://gnu.org)
Founder, Free Software Foundation (https://fsf.org)
Internet Hall-of-Famer (https://internethalloffame.org)







reply via email to

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