Documentation ¶
Index ¶
- func DumpStatementList(output io.Writer, header string, indent int, statements []Statement) error
- type DefType
- type Definition
- func DefAssign(path path.TypePath, variable string, value Expression, ...) Definition
- func DefDefine(path path.TypePath, location tokenizer.SourceLocation) Definition
- func DefImplement(path path.TypePath, function string, arguments []ProcArgument, ...) Definition
- func DefProcDecl(path path.TypePath, variable string, location tokenizer.SourceLocation) Definition
- func DefVarDef(path path.TypePath, varType path.TypePath, variable string, ...) Definition
- func DefVerbDecl(path path.TypePath, variable string, location tokenizer.SourceLocation) Definition
- type ExprType
- type Expression
- func ExprBooleanNot(expr Expression, loc tokenizer.SourceLocation) Expression
- func ExprCall(expr Expression, keywords []string, arguments []Expression, ...) Expression
- func ExprGetField(expr Expression, field string, loc tokenizer.SourceLocation) Expression
- func ExprGetLocal(name string, loc tokenizer.SourceLocation) Expression
- func ExprGetNonLocal(name string, loc tokenizer.SourceLocation) Expression
- func ExprIntegerLiteral(literal int64, loc tokenizer.SourceLocation) Expression
- func ExprNew(typepath path.TypePath, keywords []string, arguments []Expression, ...) Expression
- func ExprNone() Expression
- func ExprPathLiteral(path path.TypePath, loc tokenizer.SourceLocation) Expression
- func ExprResourceLiteral(literal string, loc tokenizer.SourceLocation) Expression
- func ExprStringConcat(exprs []Expression, loc tokenizer.SourceLocation) Expression
- func ExprStringLiteral(literal string, loc tokenizer.SourceLocation) Expression
- func ExprStringMacro(macro string, expr Expression, loc tokenizer.SourceLocation) Expression
- type File
- type ProcArgument
- type ProcArgumentAs
- type Statement
- func StatementAssign(destination Expression, value Expression, loc tokenizer.SourceLocation) Statement
- func StatementDel(expr Expression, loc tokenizer.SourceLocation) Statement
- func StatementEvaluate(expr Expression, loc tokenizer.SourceLocation) Statement
- func StatementForList(vartype dtype.DType, varname string, inExpr Expression, body []Statement, ...) Statement
- func StatementIf(condition Expression, body []Statement, loc tokenizer.SourceLocation) Statement
- func StatementNone() Statement
- func StatementReturn(loc tokenizer.SourceLocation) Statement
- func StatementSetIn(field string, expr Expression, loc tokenizer.SourceLocation) Statement
- func StatementSetTo(field string, expr Expression, loc tokenizer.SourceLocation) Statement
- func StatementWrite(destination Expression, value Expression, loc tokenizer.SourceLocation) Statement
- type StatementType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Definition ¶
type Definition struct { Type DefType Path path.TypePath VarType path.TypePath Variable string Expression Expression Arguments []ProcArgument Body []Statement SourceLoc tokenizer.SourceLocation }
func DefAssign ¶
func DefAssign(path path.TypePath, variable string, value Expression, location tokenizer.SourceLocation) Definition
func DefDefine ¶
func DefDefine(path path.TypePath, location tokenizer.SourceLocation) Definition
func DefImplement ¶
func DefImplement(path path.TypePath, function string, arguments []ProcArgument, body []Statement, location tokenizer.SourceLocation) Definition
func DefProcDecl ¶
func DefProcDecl(path path.TypePath, variable string, location tokenizer.SourceLocation) Definition
func DefVarDef ¶
func DefVarDef(path path.TypePath, varType path.TypePath, variable string, location tokenizer.SourceLocation) Definition
func DefVerbDecl ¶
func DefVerbDecl(path path.TypePath, variable string, location tokenizer.SourceLocation) Definition
type Expression ¶
type Expression struct { Type ExprType Str string Integer int64 Names []string Children []Expression Path path.TypePath SourceLoc tokenizer.SourceLocation }
func ExprBooleanNot ¶
func ExprBooleanNot(expr Expression, loc tokenizer.SourceLocation) Expression
func ExprCall ¶
func ExprCall(expr Expression, keywords []string, arguments []Expression, loc tokenizer.SourceLocation) Expression
func ExprGetField ¶
func ExprGetField(expr Expression, field string, loc tokenizer.SourceLocation) Expression
func ExprGetLocal ¶
func ExprGetLocal(name string, loc tokenizer.SourceLocation) Expression
func ExprGetNonLocal ¶
func ExprGetNonLocal(name string, loc tokenizer.SourceLocation) Expression
func ExprIntegerLiteral ¶
func ExprIntegerLiteral(literal int64, loc tokenizer.SourceLocation) Expression
func ExprNew ¶
func ExprNew(typepath path.TypePath, keywords []string, arguments []Expression, loc tokenizer.SourceLocation) Expression
func ExprNone ¶
func ExprNone() Expression
func ExprPathLiteral ¶
func ExprPathLiteral(path path.TypePath, loc tokenizer.SourceLocation) Expression
func ExprResourceLiteral ¶
func ExprResourceLiteral(literal string, loc tokenizer.SourceLocation) Expression
func ExprStringConcat ¶
func ExprStringConcat(exprs []Expression, loc tokenizer.SourceLocation) Expression
func ExprStringLiteral ¶
func ExprStringLiteral(literal string, loc tokenizer.SourceLocation) Expression
func ExprStringMacro ¶
func ExprStringMacro(macro string, expr Expression, loc tokenizer.SourceLocation) Expression
func (Expression) IsNone ¶
func (dme Expression) IsNone() bool
func (Expression) String ¶
func (dme Expression) String() string
type File ¶
type File struct { Definitions []Definition SearchPath []string Maps []string }
type ProcArgument ¶
type ProcArgument struct { Type dtype.DType Name string As ProcArgumentAs // for verbs }
type ProcArgumentAs ¶
type ProcArgumentAs int
const ( ProcArgumentNone ProcArgumentAs = iota ProcArgumentText ProcArgumentMessage ProcArgumentNum ProcArgumentIcon ProcArgumentSound ProcArgumentFile ProcArgumentKey ProcArgumentNull ProcArgumentMob ProcArgumentObj ProcArgumentTurf ProcArgumentArea ProcArgumentAnything )
func ProcArgumentFromString ¶
func ProcArgumentFromString(arg string) ProcArgumentAs
func (ProcArgumentAs) String ¶
func (t ProcArgumentAs) String() string
type Statement ¶
type Statement struct { Type StatementType VarType dtype.DType Name string From Expression To Expression Body []Statement SourceLoc tokenizer.SourceLocation }
func StatementAssign ¶
func StatementAssign(destination Expression, value Expression, loc tokenizer.SourceLocation) Statement
func StatementDel ¶
func StatementDel(expr Expression, loc tokenizer.SourceLocation) Statement
func StatementEvaluate ¶
func StatementEvaluate(expr Expression, loc tokenizer.SourceLocation) Statement
func StatementForList ¶
func StatementForList(vartype dtype.DType, varname string, inExpr Expression, body []Statement, loc tokenizer.SourceLocation) Statement
func StatementIf ¶
func StatementIf(condition Expression, body []Statement, loc tokenizer.SourceLocation) Statement
func StatementNone ¶
func StatementNone() Statement
func StatementReturn ¶
func StatementReturn(loc tokenizer.SourceLocation) Statement
func StatementSetIn ¶
func StatementSetIn(field string, expr Expression, loc tokenizer.SourceLocation) Statement
func StatementSetTo ¶
func StatementSetTo(field string, expr Expression, loc tokenizer.SourceLocation) Statement
func StatementWrite ¶
func StatementWrite(destination Expression, value Expression, loc tokenizer.SourceLocation) Statement
type StatementType ¶
type StatementType uint8
const ( StatementTypeNone StatementType = iota StatementTypeWrite StatementTypeIf StatementTypeReturn StatementTypeSetIn StatementTypeSetTo StatementTypeEvaluate StatementTypeAssign StatementTypeDel StatementTypeForList )
func (StatementType) String ¶
func (et StatementType) String() string
Click to show internal directories.
Click to hide internal directories.