From: Kevin Rodgers <kevin.d.rodgers@gmail.com>
To: help-gnu-emacs@gnu.org
Subject: Re: Interning Symbols
Date: Wed, 11 Nov 2009 23:26:14 -0700 [thread overview]
Message-ID: <hdg9pp$m5s$1@ger.gmane.org> (raw)
In-Reply-To: <e3d327da-ea98-42cb-87a7-f7718805bad6@j4g2000yqe.googlegroups.com>
Nordlöw wrote:
> Is it possible to intern a symbol and make it have a property whose
> value is a references to a another object like we do with setf()?
Do you mean, does this work:
(setq my-obarray (make-vector 1021 0))
(setf (get (intern "foo" my-obarray) 'some-property)
(evaluates-to-some-object))
I don't know why it wouldn't:
(require 'cl)
(macroexpand (quote ...)) =>
(let* ((--cl-var-- (intern "foo" my-obarray))) (put --cl-var-- (quote
some-property) (evaluates-to-some-object)))
> If I want to copy a symbol along with all its 4 components into
> another obarray do I have to manually copy (using get and set) the
> value, function def and property-list?
Yes.
--
Kevin Rodgers
Denver, Colorado, USA
prev parent reply other threads:[~2009-11-12 6:26 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-11 18:47 Interning Symbols Nordlöw
2009-11-12 6:26 ` Kevin Rodgers [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='hdg9pp$m5s$1@ger.gmane.org' \
--to=kevin.d.rodgers@gmail.com \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.