gnu.kawa.lispexpr

Class LispLanguage

public abstract class LispLanguage extends Language

Language sub-class for Lisp-like languages (including Scheme).
Field Summary
ReadTabledefaultReadTable
The default ReadTable for this language.
static Stringlookup_sym
Used for Kawa infix ':' operator.
static Stringquasiquote_sym
static Stringquote_sym
static Stringunquotesplicing_sym
static Stringunquote_sym
Method Summary
abstract ReadTablecreateReadTable()
Create a fresh ReadTable appropriate for this language.
DeclarationdeclFromField(ModuleExp mod, Object fvalue, Field fld)
protected voiddefSntxStFld(String name, String cname, String fname)
Declare in the current Environment a Syntax bound to a static field.
protected voiddefSntxStFld(String name, String cname)
protected SymbolfromLangSymbol(Object sym)
CompilationgetCompilation(Lexer lexer, SourceMessages messages)
LexergetLexer(InPort inp, SourceMessages messages)
static SymbollangSymbolToSymbol(Object sym)
Convert the Language's idea of a symbol to a gnu.mapping.Symbol.
ExpressionmakeApply(Expression func, Expression[] args)
ExpressionmakeBody(Expression[] exps)
Combine a consisting of a list of expression.
booleanparse(Compilation comp, int options)
voidresolve(Compilation comp)
Resolve names and other post-parsing processing.
booleanselfEvaluatingSymbol(Object obj)

Field Detail

defaultReadTable

public ReadTable defaultReadTable
The default ReadTable for this language.

lookup_sym

public static final String lookup_sym
Used for Kawa infix ':' operator.

quasiquote_sym

public static final String quasiquote_sym

quote_sym

public static final String quote_sym

unquotesplicing_sym

public static final String unquotesplicing_sym

unquote_sym

public static final String unquote_sym

Method Detail

createReadTable

public abstract ReadTable createReadTable()
Create a fresh ReadTable appropriate for this language.

declFromField

public Declaration declFromField(ModuleExp mod, Object fvalue, Field fld)

defSntxStFld

protected void defSntxStFld(String name, String cname, String fname)
Declare in the current Environment a Syntax bound to a static field.

Parameters: name the procedure's source-level name. cname the name of the class containing the field. fname the name of the field, which should be a static final field whose type extends kawa.lang.Syntax.

defSntxStFld

protected void defSntxStFld(String name, String cname)

fromLangSymbol

protected Symbol fromLangSymbol(Object sym)

getCompilation

public Compilation getCompilation(Lexer lexer, SourceMessages messages)

getLexer

public Lexer getLexer(InPort inp, SourceMessages messages)

langSymbolToSymbol

public static Symbol langSymbolToSymbol(Object sym)
Convert the Language's idea of a symbol to a gnu.mapping.Symbol.

makeApply

public Expression makeApply(Expression func, Expression[] args)

makeBody

public Expression makeBody(Expression[] exps)
Combine a consisting of a list of expression.

parse

public boolean parse(Compilation comp, int options)

resolve

public void resolve(Compilation comp)
Resolve names and other post-parsing processing.

selfEvaluatingSymbol

public boolean selfEvaluatingSymbol(Object obj)