[Top][All Lists]

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

Re: Interning Symbols

From: Kevin Rodgers
Subject: Re: Interning Symbols
Date: Wed, 11 Nov 2009 23:26:14 -0700
User-agent: Thunderbird (Macintosh/20090812)

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)

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?


Kevin Rodgers
Denver, Colorado, USA

reply via email to

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