Xref: utzoo comp.emacs:6002 gnu.emacs:822 Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!cs.utexas.edu!uunet!littlei!omepd!merlyn From: merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) Newsgroups: comp.emacs,gnu.emacs Subject: intern (was Re: GNU Emacs string-to-symbol function ?) Summary: it's already there Keywords: GNU Message-ID: <4366@omepd.UUCP> Date: 2 May 89 22:10:05 GMT References: <1256@novavax.UUCP> Sender: news@omepd.UUCP Reply-To: merlyn@intelob.intel.com (Randal L. Schwartz @ Stonehenge) Organization: Stonehenge; netaccess via BiiN, Hillsboro, Oregon, USA Lines: 30 In-reply-to: weiner@novavax.UUCP (Bob Weiner) In article <1256@novavax.UUCP>, weiner@novavax (Bob Weiner) writes: | Anyone know if there is a way to convert a string to a symbol-name in | GNU Emacs Lisp? ^H d i n t e r n RET intern: Return the symbol whose name is STRING. A second optional argument specifies the obarray to use; it defaults to the value of obarray. ^H d i n t e r n - s o f t RET intern-soft: Return the symbol whose name is STRING, or nil if none exists yet. A second optional argument specifies the obarray to use; it defaults to the value of obarray. Try (intern "foo") or (intern-soft "foo") Side note for elisp gurus: what happens if you (intern-soft "nil")? How do you tell? :-) :-) Just another elisp hacker (for a few more weeks...), -- /=Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095===\ { on contract to BiiN, Hillsboro, Oregon, USA, until 30 May 1989 } { ...!uunet!tektronix!biin!merlyn } { or try after 30 May 1989 } \=Cute quote: "Welcome to Oregon... home of the California Raisins!"=/