This is the mail archive of the
kawa@sources.redhat.com
mailing list for the Kawa project.
new define-variable special form for Kawa
- From: Per Bothner <per at bothner dot com>
- To: kawa at sources dot redhat dot com
- Date: Wed, 05 Nov 2003 21:18:03 -0800
- Subject: new define-variable special form for Kawa
- Syntax: define-variable name [init]
If INIT is specified and NAME does not have a global variable
binding, then INIT is evaluated, and NAME bound to the result.
Otherwise, the value bound to NAME does not change. (Note that
INIT is not evaluated if NAME does have a global variable binding.)
Also, declares to the compiler that NAME will be looked up in the
dynamic environment. This can be useful for shutting up warnings
from `--warn-undefined-variable'.
This is similar to the Common Lisp `defvar' form. However, the
Kawa version is (currently) only allowed at module level.
--
--Per Bothner
per@bothner.com http://per.bothner.com/