all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* symbols and cells
@ 2014-05-15 17:10 Christopher Howard
  2014-05-15 20:16 ` Michael Heerdegen
  0 siblings, 1 reply; 3+ messages in thread
From: Christopher Howard @ 2014-05-15 17:10 UTC (permalink / raw)
  To: Gnu Emacs Help

I'm still working through the earlier parts of the Elisp
documentation, but I am curious: How does one define the variable cell
and function cell for an /uninterned/ symbol? The docs indicate you
can do this:

(defvar sym (make-symbol "foo"))

But how do you add a function or variable value to foo without
interning it?

On a related note, I'm curious about this perverse construction:

(defvar sym1 (lambda (n) (+ 1 n)))

Is it actually possible to call the the lambda somehow?

ELISP> sym1
(lambda
  (n)
  (+ 1 n))

ELISP> (sym1)
*** Eval error ***  Symbol's function definition is void: sym1
ELISP> (eval sym1)
(lambda
  (n)
  (+ 1 n))

ELISP> ((eval sym1))
*** Eval error ***  Invalid function: (eval sym1)



^ permalink raw reply	[flat|nested] 3+ messages in thread
[parent not found: <mailman.1410.1400173825.1147.help-gnu-emacs@gnu.org>]

end of thread, other threads:[~2014-05-15 20:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-05-15 17:10 symbols and cells Christopher Howard
2014-05-15 20:16 ` Michael Heerdegen
     [not found] <mailman.1410.1400173825.1147.help-gnu-emacs@gnu.org>
2014-05-15 18:07 ` Pascal J. Bourguignon

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.