[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Macros -> declarations
- To: RWK@YUKON.SCRC.Symbolics.COM, Fahlman@CMU-CS-C.ARPA
- Subject: Macros -> declarations
- From: Bernard S. Greenberg <BSG@STONY-BROOK.SCRC.Symbolics.COM>
- Date: Thu, 9 May 85 09:43 EDT
- Cc: KMP@TENEX.SCRC.Symbolics.COM, common-lisp@SU-AI.ARPA
- In-reply-to: <850508115301.3.RWK@CROW.SCRC.Symbolics.COM>
Date: Wed, 8 May 85 11:53 EDT
From: Robert W. Kerns <RWK@SCRC-YUKON.ARPA>
Instead of DECLARE forms being allowed to be macros, why not allow the
forms INSIDE declare forms be macros? Using macros rather than
"declaration macros" lets you then use macrolet, and avoids the need for
any new "DEFDECLARE" special forms to document or implement.
This doesn't quite cover the bases, though, unless we also deal with
expanding into multiple declarations [i.e. (REGISTER X) ->
(SPECIAL X) (FIXNUM X)].
I'll propose two ways to deal with that.
1) Allow (DECLARE (FOO X) ((SPECIAL X) (FIXNUM X))) to mean the
same as (DECLARE (FOO X) (SPECIAL X) (FIXNUM X))
2) Allow (DECLARE (FOO X) (DECLARE (SPECIAL X) (FIXNUM X))). I.e.
Allow DECLARE as a declaration containing declarations.
3) Allow (DECLARE (PROGN .....)) [The onus of history.]
At any rate, RWK's whole proposal seems to cover all bases.