Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Declare ¶
type Declare struct {
Methods []DeclareLine // Stores an array of all the line
}
type DeclareLine ¶
type ExpressionIF ¶
type ExpressionIF struct {
Args []lexer.Token
Body []FormattedPacket
Keyword lexer.Token
}
Model used when if statements are found
type Format ¶
type Format struct {
Parser *parse.Parser // Holds mainly the instructions
Lexer *lexer.Lexer // Holds mainly the tokens
Manuals []FormattedPacket // Holds our entire formatter output
Position int // Scanners current position inside the array
}
func (*Format) FuncCreate ¶
func (F *Format) FuncCreate(body *parse.FunctionBody) (*FormattedPacket, error)
FuncCreate will return the function inside a formatted packet
func (*Format) IF ¶
func (F *Format) IF(body *parse.IfStatement) (*FormattedPacket, error)
IF will work the needed information within the if statement
type FormattedPacket ¶
type FormattedPacket struct {
Node FormatNode // Stores the formatted nodeType
DeclareStatement *Declare // Holds information if the statement is a declaration
CallStatement *FunctionCall // Holds information if the statement is a call statement
IFCall []ExpressionIF // Holds information if the call statement is if statement
Returns []lexer.Token // Holds information if the statement is a return statement
Axis []lexer.Token // Holds all the token axis attributes
FunctionBody *FunctionBody
}
Stores the formatted node output
type FunctionBody ¶
Click to show internal directories.
Click to hide internal directories.