Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Lisp > Any programmabl...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 8 Topic 12466 of 13149
Post > Topic >>

Any programmable way to ask whether a symbol has been proclaimed special?

by usenet2.3.CalRobert@[EMAIL PROTECTED] (Robert Maas, http://tinyurl May 11, 2008 at 09:20 PM

Today I got in a situation where I thought I had declared a
particular symbol to be special, by means of DEFVAR most likely,
but was getting strange behaviour related to it. I wanted to
diagnose the problem by first learning whether the symbol had been
proclaimed special or not. I first looked on the property list of
that symbol, but there was nothing there at all, no SPECIAL flag or
anything like that. I then spent a half hour searching through
CLtL1 without finding any predicate that tells whether a symbol is
special (already) or not. I checked the HyperSpec and couldn't find
any such predicate there either. Then suddenly I remembered
DESCRIBE, which printed out among other things:
  It is a special variable; no current value.
OK, so I should have thought of that first. But there's no SPECIALP
predicate or anything else I can find. How does DESCRIBE know that
the symbol is special? How does the JIT compiler built into the
REP loop know that it's special when it's deciding whether to do
lexical or special bindings? If I ever want to automate the
checking of several symbols to see if I forgot to proclaim any of
them special, how can I do that, except by binding standard output
to a string-output-string and calling DESCRIBE in that context and
then parsing the resultant string of output from DESCRIBE??

This is in CMUCL, if it makes any difference. I'm hoping for some
ANSI-CL function (predicate) rather than a CMUCL-specific function
(predicate), but I'm curious in any case.
 




 8 Posts in Topic:
Any programmable way to ask whether a symbol has been proclaimed
usenet2.3.CalRobert@[EMAI  2008-05-11 21:20:30 
Re: Any programmable way to ask whether a symbol has been procla
Kent M Pitman <pitman@  2008-05-12 02:19:25 
Re: Any programmable way to ask whether a symbol has been procla
Chris Barts <chbarts+u  2008-05-12 17:27:41 
Re: Any programmable way to ask whether a symbol has been procla
Juho Snellman <jsnell@  2008-05-13 03:32:22 
Re: Any programmable way to ask whether a symbol has been procla
Kent M Pitman <pitman@  2008-05-12 23:38:20 
Re: Any programmable way to ask whether a symbol has been procla
jcornez@[EMAIL PROTECTED]  2008-05-16 06:57:30 
Re: Any programmable way to ask whether a symbol has been procla
rpw3@[EMAIL PROTECTED] (  2008-05-12 03:08:26 
Re: Any programmable way to ask whether a symbol has been procla
Duane Rettig <duane@[E  2008-05-12 08:17:26 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Fri Jul 25 23:23:49 CDT 2008.