Package kawa.standard
Class define
- java.lang.Object
-
- kawa.lang.Syntax
-
- kawa.standard.define
-
- All Implemented Interfaces:
gnu.kawa.format.Printable
,Named
public class define extends Syntax
The Syntax transformer that re-writes the "%define" internal form. This is used to implement define, define-private, and define-constant. Syntax:(%define name code type value)
. Thename
is an identifier (String
orSymbol
) orDeclaration
. Thecode
is an integer mask, where 1 means type specified, 2 means a function definition, 4 means private, 8 means constant, 16 means an early constant., and 32 means a fluid variable (define-variable). As a special case, define-procedure is 1+2+8+16=27 Thetype
is the declarated type ornull
. Thevalue
is the initializing value.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Expression
rewriteForm(Pair form, Translator tr)
void
scanForm(Pair st, ScopeExp defs, Translator tr)
-
-
-
Field Detail
-
defineRaw
public static final define defineRaw
-
-
Constructor Detail
-
define
public define(Lambda lambda)
-
-
Method Detail
-
scanForm
public void scanForm(Pair st, ScopeExp defs, Translator tr)
-
rewriteForm
public Expression rewriteForm(Pair form, Translator tr)
- Overrides:
rewriteForm
in classSyntax
-
-