Parser
hscript.Parser (Class)
Instance Members
line: Int
opChars: String
identChars: String
opPriority: Map
opRightAssoc: Map
preprocesorValues: Map
allows to check for #if / #else in code
allowJSON: Bool
activate JSON compatiblity
allowTypes: Bool
allow types declarations
allowMetadata: Bool
allow haxe metadata declarations
resumeErrors: Bool
resume from parsing errors (when parsing incomplete code, during completion for example)
Name | Type |
---|---|
err |
Anonymous |
pmin |
Int |
pmax |
Int |
Name | Type |
---|---|
c |
Int |
Name | Type | Default |
---|---|---|
s |
String | |
origin |
String | "hscript" |
position |
Int | 0 |
Returns |
---|
Expr |
Name | Type | Default |
---|---|---|
content |
String | |
origin |
String | "hscript" |
position |
Int | 0 |
Returns |
---|
Array |
new(): Void
Private Members
input: String
readPos: Int
offset: Int
currentPos: Int
char: Int
uid: Int
origin: String
tokenMin: Int
tokenMax: Int
oldTokenMin: Int
oldTokenMax: Int
tokens: List
preprocStack: Array<AnonStruct>
Name | Type |
---|---|
origin |
String |
pos |
Int |
unexpected(tk: Anonymous): Dynamic
Name | Type |
---|---|
tk |
Anonymous |
Returns |
---|
Dynamic |
push(tk: Anonymous): Void
Name | Type |
---|---|
tk |
Anonymous |
ensure(tk: Anonymous): Void
Name | Type |
---|---|
tk |
Anonymous |
ensureToken(tk: Anonymous): Void
Name | Type |
---|---|
tk |
Anonymous |
maybe(tk: Anonymous): Bool
Name | Type |
---|---|
tk |
Anonymous |
Returns |
---|
Bool |
getIdent(): String
Returns |
---|
String |
expr(e: Expr): Anonymous
Name | Type |
---|---|
e |
Expr |
Returns |
---|
Anonymous |
Name | Type |
---|---|
e |
Expr |
Returns |
---|
Int |
Name | Type |
---|---|
e |
Expr |
Returns |
---|
Int |
Name | Type | Default |
---|---|---|
e |
Null |
|
pmin |
Int | (optional) |
pmax |
Int | (optional) |
Returns |
---|
Expr |
Name | Type |
---|---|
e |
Null<Expr> |
Returns |
---|
Bool |
Name | Type |
---|---|
exprs |
Array<Expr> |
Name | Type |
---|---|
p1 |
Null<Int> |
Returns |
---|
Expr |
Returns |
---|
Null<Expr> |
Name | Type |
---|---|
args |
Array<Argument> |
pmin |
Null<Int> |
Returns |
---|
Expr |
Returns |
---|
Null<Array<Null<Expr>>> |
Name | Type |
---|---|
tmp |
String |
e |
Expr |
Returns |
---|
Null<Expr> |
Name | Type |
---|---|
op |
String |
e |
Null<Expr> |
Returns |
---|
Null<Expr> |
Name | Type |
---|---|
op |
String |
e1 |
Expr |
e |
Null<Expr> |
Returns |
---|
Expr |
Name | Type |
---|---|
id |
String |
Returns |
---|
Null<Expr> |
Name | Type |
---|---|
e1 |
Expr |
Returns |
---|
Expr |
Returns |
---|
Array<Argument> |
Returns |
---|
AnonStruct |
Returns |
---|
Array<String> |
Returns |
---|
Anonymous |
Name | Type |
---|---|
t |
Anonymous |
Returns |
---|
Anonymous |
Name | Type |
---|---|
etk |
Anonymous |
Returns |
---|
Array<Null<Expr>> |
parseMetadata(): Metadata
Returns |
---|
Metadata |
Returns |
---|
AnonStruct |
Returns |
---|
Anonymous |
parseField(): FieldDecl
Returns |
---|
FieldDecl |
readChar(): Int
Returns |
---|
Int |
Name | Type |
---|---|
until |
Int |
Returns |
---|
String |
Returns |
---|
Anonymous |
Name | Type |
---|---|
id |
String |
Returns |
---|
Dynamic |
parsePreproCond(): Expr
Returns |
---|
Expr |
Name | Type |
---|---|
e |
Expr |
Returns |
---|
Bool |
preprocess(id: String): Anonymous
Name | Type |
---|---|
id |
String |
Returns |
---|
Anonymous |
skipTokens(): Void
Name | Type |
---|---|
op |
String |
char |
Int |
Returns |
---|
Anonymous |
constString(c: Anonymous): String
Name | Type |
---|---|
c |
Anonymous |
Returns |
---|
String |
tokenString(t: Anonymous): String
Name | Type |
---|---|
t |
Anonymous |
Returns |
---|
String |