this post was submitted on 16 Oct 2023
1 points (66.7% liked)

Emacs

311 readers
1 users here now

A community for the timeless and infinitely powerful editor. Want to see what Emacs is capable of?!

Get Emacs

Rules

  1. Posts should be emacs related
  2. Be kind please
  3. Yes, we already know: Google results for "emacs" and "vi" link to each other. We good.

Emacs Resources

Emacs Tutorials

Useful Emacs configuration files and distributions

Quick pain-saver tip

founded 1 year ago
MODERATORS
 

Once I saw nil or 'nil from some (setq ..), it usually worried me.

The barely nil appears to be a variable name no more than `foo bar zoo` and there shoud be a value it points to.The quoted 'nil seems to be a data or a value in data mode and there might exist a name it is given.it looks no difference with symbols as 'nilll 'nilllllll or 'nillllllllll as data.

Every time see them, I find myself hesitating, uncertain and disturbing.

This picture tells they are identical and comfort me to get an insight that lisp is much more pragmatic in evovling by patching up.

As a result, I stop worring its theoretical consistency and confidently proceed with using `nil`.

4 disguises of nil

The wizard book SICP states it as:

Lisp was not the product of a concerted design effort. Instead, it evolved informally in an experimental manner in response to users' needs and to pragmatic implementation considerations.

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 1 points 1 year ago

There are a variety of "self-quoting" constructs in elisp (including all :keywords!).

(eq (quote nil) nil) ; ==> t  
(eq (quote t) t) ; ==> t  
(eq (quote :some-keyword) :some-keyword) ; ==> t