brighterscript 1.0.0-alpha.25 → 1.0.0-alpha.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/bsconfig.schema.json +5 -0
- package/dist/AstValidationSegmenter.js +4 -4
- package/dist/AstValidationSegmenter.js.map +1 -1
- package/dist/BsConfig.d.ts +1 -0
- package/dist/Program.d.ts +1 -1
- package/dist/Program.js +18 -19
- package/dist/Program.js.map +1 -1
- package/dist/Scope.d.ts +0 -5
- package/dist/Scope.js +8 -14
- package/dist/Scope.js.map +1 -1
- package/dist/XmlScope.d.ts +0 -5
- package/dist/XmlScope.js +3 -21
- package/dist/XmlScope.js.map +1 -1
- package/dist/astUtils/CachedLookups.js +3 -3
- package/dist/astUtils/CachedLookups.js.map +1 -1
- package/dist/astUtils/Editor.spec.js +1 -1
- package/dist/astUtils/Editor.spec.js.map +1 -1
- package/dist/astUtils/creators.js +32 -12
- package/dist/astUtils/creators.js.map +1 -1
- package/dist/astUtils/creators.spec.js +4 -4
- package/dist/astUtils/creators.spec.js.map +1 -1
- package/dist/astUtils/reflection.d.ts +1 -1
- package/dist/astUtils/reflection.js +1 -1
- package/dist/astUtils/reflection.js.map +1 -1
- package/dist/astUtils/reflection.spec.js +59 -42
- package/dist/astUtils/reflection.spec.js.map +1 -1
- package/dist/astUtils/visitors.spec.js +30 -19
- package/dist/astUtils/visitors.spec.js.map +1 -1
- package/dist/bscPlugin/BscPlugin.d.ts +2 -1
- package/dist/bscPlugin/BscPlugin.js +7 -3
- package/dist/bscPlugin/BscPlugin.js.map +1 -1
- package/dist/bscPlugin/CallExpressionInfo.js +7 -7
- package/dist/bscPlugin/CallExpressionInfo.js.map +1 -1
- package/dist/bscPlugin/SignatureHelpUtil.js +5 -4
- package/dist/bscPlugin/SignatureHelpUtil.js.map +1 -1
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.js +2 -2
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.js.map +1 -1
- package/dist/bscPlugin/completions/CompletionsProcessor.js +3 -3
- package/dist/bscPlugin/completions/CompletionsProcessor.js.map +1 -1
- package/dist/bscPlugin/definition/DefinitionProvider.d.ts +13 -0
- package/dist/bscPlugin/definition/DefinitionProvider.js +210 -0
- package/dist/bscPlugin/definition/DefinitionProvider.js.map +1 -0
- package/dist/bscPlugin/definition/DefinitionProvider.spec.d.ts +1 -0
- package/dist/bscPlugin/definition/DefinitionProvider.spec.js +88 -0
- package/dist/bscPlugin/definition/DefinitionProvider.spec.js.map +1 -0
- package/dist/bscPlugin/hover/HoverProcessor.js +2 -2
- package/dist/bscPlugin/hover/HoverProcessor.js.map +1 -1
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.js +0 -2
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.js.map +1 -1
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.js +8 -6
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.js.map +1 -1
- package/dist/bscPlugin/validation/BrsFileValidator.js +28 -28
- package/dist/bscPlugin/validation/BrsFileValidator.js.map +1 -1
- package/dist/bscPlugin/validation/ScopeValidator.d.ts +4 -0
- package/dist/bscPlugin/validation/ScopeValidator.js +51 -20
- package/dist/bscPlugin/validation/ScopeValidator.js.map +1 -1
- package/dist/bscPlugin/validation/ScopeValidator.spec.js +73 -0
- package/dist/bscPlugin/validation/ScopeValidator.spec.js.map +1 -1
- package/dist/files/BrsFile.Class.spec.js +3 -3
- package/dist/files/BrsFile.Class.spec.js.map +1 -1
- package/dist/files/BrsFile.d.ts +4 -11
- package/dist/files/BrsFile.js +39 -206
- package/dist/files/BrsFile.js.map +1 -1
- package/dist/files/BrsFile.spec.js +56 -2
- package/dist/files/BrsFile.spec.js.map +1 -1
- package/dist/interfaces.d.ts +32 -1
- package/dist/interfaces.js.map +1 -1
- package/dist/parser/AstNode.spec.js +6 -6
- package/dist/parser/AstNode.spec.js.map +1 -1
- package/dist/parser/Expression.d.ts +288 -145
- package/dist/parser/Expression.js +310 -271
- package/dist/parser/Expression.js.map +1 -1
- package/dist/parser/Parser.Class.spec.js +11 -11
- package/dist/parser/Parser.Class.spec.js.map +1 -1
- package/dist/parser/Parser.d.ts +5 -0
- package/dist/parser/Parser.js +315 -120
- package/dist/parser/Parser.js.map +1 -1
- package/dist/parser/Parser.spec.js +42 -185
- package/dist/parser/Parser.spec.js.map +1 -1
- package/dist/parser/Statement.d.ts +332 -188
- package/dist/parser/Statement.js +475 -364
- package/dist/parser/Statement.js.map +1 -1
- package/dist/parser/Statement.spec.js +2 -2
- package/dist/parser/Statement.spec.js.map +1 -1
- package/dist/parser/tests/controlFlow/For.spec.js +1 -1
- package/dist/parser/tests/controlFlow/For.spec.js.map +1 -1
- package/dist/parser/tests/controlFlow/ForEach.spec.js +2 -2
- package/dist/parser/tests/controlFlow/ForEach.spec.js.map +1 -1
- package/dist/parser/tests/expression/AssociativeArrayLiterals.spec.js +1 -1
- package/dist/parser/tests/expression/AssociativeArrayLiterals.spec.js.map +1 -1
- package/dist/parser/tests/expression/Call.spec.js +11 -11
- package/dist/parser/tests/expression/Call.spec.js.map +1 -1
- package/dist/parser/tests/expression/Indexing.spec.js +30 -5
- package/dist/parser/tests/expression/Indexing.spec.js.map +1 -1
- package/dist/parser/tests/expression/NullCoalescenceExpression.spec.js +2 -2
- package/dist/parser/tests/expression/NullCoalescenceExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/TernaryExpression.spec.js +2 -2
- package/dist/parser/tests/expression/TernaryExpression.spec.js.map +1 -1
- package/dist/parser/tests/statement/ConstStatement.spec.js +1 -1
- package/dist/parser/tests/statement/ConstStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/Dim.spec.js +8 -8
- package/dist/parser/tests/statement/Dim.spec.js.map +1 -1
- package/dist/parser/tests/statement/Enum.spec.js +2 -2
- package/dist/parser/tests/statement/Enum.spec.js.map +1 -1
- package/dist/parser/tests/statement/LibraryStatement.spec.js +2 -2
- package/dist/parser/tests/statement/LibraryStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/Misc.spec.js +2 -2
- package/dist/parser/tests/statement/Misc.spec.js.map +1 -1
- package/dist/parser/tests/statement/PrintStatement.spec.js +1 -1
- package/dist/parser/tests/statement/TryCatch.spec.js +1 -1
- package/dist/parser/tests/statement/TryCatch.spec.js.map +1 -1
- package/dist/types/BuiltInInterfaceAdder.js +11 -4
- package/dist/types/BuiltInInterfaceAdder.js.map +1 -1
- package/dist/util.d.ts +17 -8
- package/dist/util.js +96 -51
- package/dist/util.js.map +1 -1
- package/dist/validators/ClassValidator.js +6 -6
- package/dist/validators/ClassValidator.js.map +1 -1
- package/package.json +1 -1
|
@@ -20,15 +20,13 @@ import { InterfaceType } from '../types/InterfaceType';
|
|
|
20
20
|
import type { BscType } from '../types/BscType';
|
|
21
21
|
import { TypedFunctionType } from '../types/TypedFunctionType';
|
|
22
22
|
export declare class EmptyStatement extends Statement {
|
|
23
|
+
constructor(options?: {
|
|
24
|
+
range?: Range;
|
|
25
|
+
});
|
|
23
26
|
/**
|
|
24
27
|
* Create a negative range to indicate this is an interpolated location
|
|
25
28
|
*/
|
|
26
29
|
range: Range;
|
|
27
|
-
constructor(
|
|
28
|
-
/**
|
|
29
|
-
* Create a negative range to indicate this is an interpolated location
|
|
30
|
-
*/
|
|
31
|
-
range?: Range);
|
|
32
30
|
readonly kind = AstNodeKind.EmptyStatement;
|
|
33
31
|
transpile(state: BrsTranspileState): any[];
|
|
34
32
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
@@ -37,8 +35,10 @@ export declare class EmptyStatement extends Statement {
|
|
|
37
35
|
* This is a top-level statement. Consider this the root of the AST
|
|
38
36
|
*/
|
|
39
37
|
export declare class Body extends Statement implements TypedefProvider {
|
|
38
|
+
constructor(options?: {
|
|
39
|
+
statements?: Statement[];
|
|
40
|
+
});
|
|
40
41
|
statements: Statement[];
|
|
41
|
-
constructor(statements?: Statement[]);
|
|
42
42
|
readonly kind = AstNodeKind.Body;
|
|
43
43
|
symbolTable: SymbolTable;
|
|
44
44
|
get range(): Range;
|
|
@@ -47,12 +47,20 @@ export declare class Body extends Statement implements TypedefProvider {
|
|
|
47
47
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
48
48
|
}
|
|
49
49
|
export declare class AssignmentStatement extends Statement {
|
|
50
|
-
|
|
51
|
-
|
|
50
|
+
constructor(options: {
|
|
51
|
+
name: Identifier;
|
|
52
|
+
equals?: Token;
|
|
53
|
+
value: Expression;
|
|
54
|
+
as?: Token;
|
|
55
|
+
typeExpression?: TypeExpression;
|
|
56
|
+
});
|
|
57
|
+
tokens: {
|
|
58
|
+
equals?: Token;
|
|
59
|
+
name: Identifier;
|
|
60
|
+
as?: Token;
|
|
61
|
+
};
|
|
52
62
|
value: Expression;
|
|
53
|
-
|
|
54
|
-
typeExpression?: TypeExpression;
|
|
55
|
-
constructor(equals: Token, name: Identifier, value: Expression, asToken?: Token, typeExpression?: TypeExpression);
|
|
63
|
+
typeExpression: TypeExpression;
|
|
56
64
|
readonly kind = AstNodeKind.AssignmentStatement;
|
|
57
65
|
readonly range: Range;
|
|
58
66
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
@@ -60,25 +68,34 @@ export declare class AssignmentStatement extends Statement {
|
|
|
60
68
|
getType(options: GetTypeOptions): BscType;
|
|
61
69
|
}
|
|
62
70
|
export declare class Block extends Statement {
|
|
71
|
+
constructor(options: {
|
|
72
|
+
statements: Statement[];
|
|
73
|
+
startingRange: Range;
|
|
74
|
+
});
|
|
63
75
|
readonly statements: Statement[];
|
|
64
76
|
readonly startingRange: Range;
|
|
65
|
-
constructor(statements: Statement[], startingRange: Range);
|
|
66
77
|
readonly kind = AstNodeKind.Block;
|
|
67
78
|
readonly range: Range;
|
|
68
79
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
69
80
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
70
81
|
}
|
|
71
82
|
export declare class ExpressionStatement extends Statement {
|
|
83
|
+
constructor(options: {
|
|
84
|
+
expression: Expression;
|
|
85
|
+
});
|
|
72
86
|
readonly expression: Expression;
|
|
73
|
-
constructor(expression: Expression);
|
|
74
87
|
readonly kind = AstNodeKind.ExpressionStatement;
|
|
75
88
|
readonly range: Range;
|
|
76
89
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
77
90
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
78
91
|
}
|
|
79
92
|
export declare class CommentStatement extends Statement implements Expression, TypedefProvider {
|
|
80
|
-
|
|
81
|
-
|
|
93
|
+
constructor(options: {
|
|
94
|
+
comments: Token[];
|
|
95
|
+
});
|
|
96
|
+
tokens: {
|
|
97
|
+
comments: Token[];
|
|
98
|
+
};
|
|
82
99
|
readonly kind = AstNodeKind.CommentStatement;
|
|
83
100
|
range: Range;
|
|
84
101
|
get text(): string;
|
|
@@ -87,33 +104,38 @@ export declare class CommentStatement extends Statement implements Expression, T
|
|
|
87
104
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
88
105
|
}
|
|
89
106
|
export declare class ExitForStatement extends Statement {
|
|
107
|
+
constructor(options?: {
|
|
108
|
+
exitFor?: Token;
|
|
109
|
+
});
|
|
90
110
|
readonly tokens: {
|
|
91
|
-
exitFor
|
|
111
|
+
exitFor?: Token;
|
|
92
112
|
};
|
|
93
|
-
constructor(tokens: {
|
|
94
|
-
exitFor: Token;
|
|
95
|
-
});
|
|
96
113
|
readonly kind = AstNodeKind.ExitForStatement;
|
|
97
114
|
readonly range: Range;
|
|
98
|
-
transpile(state: BrsTranspileState): SourceNode[];
|
|
115
|
+
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
99
116
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
100
117
|
}
|
|
101
118
|
export declare class ExitWhileStatement extends Statement {
|
|
119
|
+
constructor(options?: {
|
|
120
|
+
exitWhile?: Token;
|
|
121
|
+
});
|
|
102
122
|
readonly tokens: {
|
|
103
|
-
exitWhile
|
|
123
|
+
exitWhile?: Token;
|
|
104
124
|
};
|
|
105
|
-
constructor(tokens: {
|
|
106
|
-
exitWhile: Token;
|
|
107
|
-
});
|
|
108
125
|
readonly kind = AstNodeKind.ExitWhileStatement;
|
|
109
126
|
readonly range: Range;
|
|
110
|
-
transpile(state: BrsTranspileState): SourceNode[];
|
|
127
|
+
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
111
128
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
112
129
|
}
|
|
113
130
|
export declare class FunctionStatement extends Statement implements TypedefProvider {
|
|
114
|
-
|
|
131
|
+
constructor(options: {
|
|
132
|
+
name: Identifier;
|
|
133
|
+
func: FunctionExpression;
|
|
134
|
+
});
|
|
135
|
+
tokens: {
|
|
136
|
+
name: Identifier;
|
|
137
|
+
};
|
|
115
138
|
func: FunctionExpression;
|
|
116
|
-
constructor(name: Identifier, func: FunctionExpression);
|
|
117
139
|
readonly kind: AstNodeKind;
|
|
118
140
|
readonly range: Range;
|
|
119
141
|
/**
|
|
@@ -127,8 +149,18 @@ export declare class FunctionStatement extends Statement implements TypedefProvi
|
|
|
127
149
|
getType(options: GetTypeOptions): TypedFunctionType;
|
|
128
150
|
}
|
|
129
151
|
export declare class IfStatement extends Statement {
|
|
152
|
+
constructor(options: {
|
|
153
|
+
if?: Token;
|
|
154
|
+
then?: Token;
|
|
155
|
+
else?: Token;
|
|
156
|
+
endIf?: Token;
|
|
157
|
+
condition: Expression;
|
|
158
|
+
thenBranch: Block;
|
|
159
|
+
elseBranch?: IfStatement | Block;
|
|
160
|
+
isInline?: boolean;
|
|
161
|
+
});
|
|
130
162
|
readonly tokens: {
|
|
131
|
-
if
|
|
163
|
+
if?: Token;
|
|
132
164
|
then?: Token;
|
|
133
165
|
else?: Token;
|
|
134
166
|
endIf?: Token;
|
|
@@ -137,21 +169,20 @@ export declare class IfStatement extends Statement {
|
|
|
137
169
|
readonly thenBranch: Block;
|
|
138
170
|
readonly elseBranch?: IfStatement | Block;
|
|
139
171
|
readonly isInline?: boolean;
|
|
140
|
-
constructor(tokens: {
|
|
141
|
-
if: Token;
|
|
142
|
-
then?: Token;
|
|
143
|
-
else?: Token;
|
|
144
|
-
endIf?: Token;
|
|
145
|
-
}, condition: Expression, thenBranch: Block, elseBranch?: IfStatement | Block, isInline?: boolean);
|
|
146
172
|
readonly kind = AstNodeKind.IfStatement;
|
|
147
173
|
readonly range: Range;
|
|
148
174
|
transpile(state: BrsTranspileState): any[];
|
|
149
175
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
150
176
|
}
|
|
151
177
|
export declare class IncrementStatement extends Statement {
|
|
178
|
+
constructor(options: {
|
|
179
|
+
value: Expression;
|
|
180
|
+
operator: Token;
|
|
181
|
+
});
|
|
152
182
|
readonly value: Expression;
|
|
153
|
-
readonly
|
|
154
|
-
|
|
183
|
+
readonly tokens: {
|
|
184
|
+
operator: Token;
|
|
185
|
+
};
|
|
155
186
|
readonly kind = AstNodeKind.IncrementStatement;
|
|
156
187
|
readonly range: Range;
|
|
157
188
|
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
@@ -169,59 +200,69 @@ export interface PrintSeparatorSpace extends Token {
|
|
|
169
200
|
* Represents a `print` statement within BrightScript.
|
|
170
201
|
*/
|
|
171
202
|
export declare class PrintStatement extends Statement {
|
|
172
|
-
readonly tokens: {
|
|
173
|
-
print: Token;
|
|
174
|
-
};
|
|
175
|
-
readonly expressions: Array<Expression | PrintSeparatorTab | PrintSeparatorSpace>;
|
|
176
203
|
/**
|
|
177
204
|
* Creates a new internal representation of a BrightScript `print` statement.
|
|
178
|
-
* @param
|
|
179
|
-
* @param
|
|
180
|
-
* @param expressions an array of expressions or `PrintSeparator`s to be evaluated and printed.
|
|
205
|
+
* @param options the options for this statement
|
|
206
|
+
* @param options.print a print token
|
|
207
|
+
* @param options.expressions an array of expressions or `PrintSeparator`s to be evaluated and printed.
|
|
181
208
|
*/
|
|
182
|
-
constructor(
|
|
209
|
+
constructor(options: {
|
|
210
|
+
print: Token;
|
|
211
|
+
expressions: Array<Expression | PrintSeparatorTab | PrintSeparatorSpace>;
|
|
212
|
+
});
|
|
213
|
+
readonly tokens: {
|
|
183
214
|
print: Token;
|
|
184
|
-
}
|
|
215
|
+
};
|
|
216
|
+
readonly expressions: Array<Expression | PrintSeparatorTab | PrintSeparatorSpace>;
|
|
185
217
|
readonly kind = AstNodeKind.PrintStatement;
|
|
186
218
|
readonly range: Range;
|
|
187
219
|
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
188
220
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
189
221
|
}
|
|
190
222
|
export declare class DimStatement extends Statement {
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
223
|
+
constructor(options: {
|
|
224
|
+
dim?: Token;
|
|
225
|
+
name: Identifier;
|
|
226
|
+
openingSquare?: Token;
|
|
227
|
+
dimensions: Expression[];
|
|
228
|
+
closingSquare?: Token;
|
|
229
|
+
});
|
|
230
|
+
readonly tokens: {
|
|
231
|
+
dim?: Token;
|
|
232
|
+
name: Identifier;
|
|
233
|
+
openingSquare?: Token;
|
|
234
|
+
closingSquare?: Token;
|
|
235
|
+
};
|
|
236
|
+
dimensions: Expression[];
|
|
197
237
|
readonly kind = AstNodeKind.DimStatement;
|
|
198
238
|
range: Range;
|
|
199
239
|
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
200
240
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
241
|
+
getType(options: GetTypeOptions): BscType;
|
|
201
242
|
}
|
|
202
243
|
export declare class GotoStatement extends Statement {
|
|
244
|
+
constructor(options: {
|
|
245
|
+
goto?: Token;
|
|
246
|
+
label: Token;
|
|
247
|
+
});
|
|
203
248
|
readonly tokens: {
|
|
204
|
-
goto
|
|
249
|
+
goto?: Token;
|
|
205
250
|
label: Token;
|
|
206
251
|
};
|
|
207
|
-
constructor(tokens: {
|
|
208
|
-
goto: Token;
|
|
209
|
-
label: Token;
|
|
210
|
-
});
|
|
211
252
|
readonly kind = AstNodeKind.GotoStatement;
|
|
212
253
|
readonly range: Range;
|
|
213
254
|
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
214
255
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
215
256
|
}
|
|
216
257
|
export declare class LabelStatement extends Statement {
|
|
258
|
+
constructor(options: {
|
|
259
|
+
name: Token;
|
|
260
|
+
colon?: Token;
|
|
261
|
+
});
|
|
217
262
|
readonly tokens: {
|
|
218
|
-
|
|
263
|
+
name: Token;
|
|
219
264
|
colon: Token;
|
|
220
265
|
};
|
|
221
|
-
constructor(tokens: {
|
|
222
|
-
identifier: Token;
|
|
223
|
-
colon: Token;
|
|
224
|
-
});
|
|
225
266
|
readonly kind = AstNodeKind.LabelStatement;
|
|
226
267
|
readonly range: Range;
|
|
227
268
|
getLeadingTrivia(): Token[];
|
|
@@ -229,98 +270,122 @@ export declare class LabelStatement extends Statement {
|
|
|
229
270
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
230
271
|
}
|
|
231
272
|
export declare class ReturnStatement extends Statement {
|
|
273
|
+
constructor(options?: {
|
|
274
|
+
return?: Token;
|
|
275
|
+
value?: Expression;
|
|
276
|
+
});
|
|
232
277
|
readonly tokens: {
|
|
233
278
|
return: Token;
|
|
234
279
|
};
|
|
235
280
|
readonly value?: Expression;
|
|
236
|
-
constructor(tokens: {
|
|
237
|
-
return: Token;
|
|
238
|
-
}, value?: Expression);
|
|
239
281
|
readonly kind = AstNodeKind.ReturnStatement;
|
|
240
282
|
readonly range: Range;
|
|
241
283
|
transpile(state: BrsTranspileState): any[];
|
|
242
284
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
243
285
|
}
|
|
244
286
|
export declare class EndStatement extends Statement {
|
|
287
|
+
constructor(options?: {
|
|
288
|
+
end?: Token;
|
|
289
|
+
});
|
|
245
290
|
readonly tokens: {
|
|
246
|
-
end
|
|
291
|
+
end?: Token;
|
|
247
292
|
};
|
|
248
|
-
constructor(tokens: {
|
|
249
|
-
end: Token;
|
|
250
|
-
});
|
|
251
293
|
readonly kind = AstNodeKind.EndStatement;
|
|
252
294
|
readonly range: Range;
|
|
253
295
|
transpile(state: BrsTranspileState): SourceNode[];
|
|
254
296
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
255
297
|
}
|
|
256
298
|
export declare class StopStatement extends Statement {
|
|
299
|
+
constructor(options?: {
|
|
300
|
+
stop?: Token;
|
|
301
|
+
});
|
|
257
302
|
readonly tokens: {
|
|
258
|
-
stop
|
|
303
|
+
stop?: Token;
|
|
259
304
|
};
|
|
260
|
-
constructor(tokens: {
|
|
261
|
-
stop: Token;
|
|
262
|
-
});
|
|
263
305
|
readonly kind = AstNodeKind.StopStatement;
|
|
264
306
|
readonly range: Range;
|
|
265
307
|
transpile(state: BrsTranspileState): SourceNode[];
|
|
266
308
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
267
309
|
}
|
|
268
310
|
export declare class ForStatement extends Statement {
|
|
269
|
-
|
|
311
|
+
constructor(options: {
|
|
312
|
+
for?: Token;
|
|
313
|
+
counterDeclaration: AssignmentStatement;
|
|
314
|
+
to?: Token;
|
|
315
|
+
finalValue: Expression;
|
|
316
|
+
body: Block;
|
|
317
|
+
endFor?: Token;
|
|
318
|
+
step?: Token;
|
|
319
|
+
increment?: Expression;
|
|
320
|
+
});
|
|
321
|
+
readonly tokens: {
|
|
322
|
+
for?: Token;
|
|
323
|
+
to?: Token;
|
|
324
|
+
endFor?: Token;
|
|
325
|
+
step?: Token;
|
|
326
|
+
};
|
|
270
327
|
counterDeclaration: AssignmentStatement;
|
|
271
|
-
toToken: Token;
|
|
272
328
|
finalValue: Expression;
|
|
273
329
|
body: Block;
|
|
274
|
-
endForToken: Token;
|
|
275
|
-
stepToken?: Token;
|
|
276
330
|
increment?: Expression;
|
|
277
|
-
constructor(forToken: Token, counterDeclaration: AssignmentStatement, toToken: Token, finalValue: Expression, body: Block, endForToken: Token, stepToken?: Token, increment?: Expression);
|
|
278
331
|
readonly kind = AstNodeKind.ForStatement;
|
|
279
332
|
readonly range: Range;
|
|
280
333
|
transpile(state: BrsTranspileState): any[];
|
|
281
334
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
282
335
|
}
|
|
283
336
|
export declare class ForEachStatement extends Statement {
|
|
337
|
+
constructor(options: {
|
|
338
|
+
forEach?: Token;
|
|
339
|
+
item: Token;
|
|
340
|
+
in?: Token;
|
|
341
|
+
target: Expression;
|
|
342
|
+
body: Block;
|
|
343
|
+
endFor?: Token;
|
|
344
|
+
});
|
|
284
345
|
readonly tokens: {
|
|
285
|
-
forEach
|
|
286
|
-
|
|
287
|
-
|
|
346
|
+
forEach?: Token;
|
|
347
|
+
item: Token;
|
|
348
|
+
in?: Token;
|
|
349
|
+
endFor?: Token;
|
|
288
350
|
};
|
|
289
|
-
readonly item: Token;
|
|
290
|
-
readonly target: Expression;
|
|
291
351
|
readonly body: Block;
|
|
292
|
-
|
|
293
|
-
forEach: Token;
|
|
294
|
-
in: Token;
|
|
295
|
-
endFor: Token;
|
|
296
|
-
}, item: Token, target: Expression, body: Block);
|
|
352
|
+
readonly target: Expression;
|
|
297
353
|
readonly kind = AstNodeKind.ForEachStatement;
|
|
298
354
|
readonly range: Range;
|
|
299
355
|
transpile(state: BrsTranspileState): any[];
|
|
300
356
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
301
357
|
}
|
|
302
358
|
export declare class WhileStatement extends Statement {
|
|
359
|
+
constructor(options: {
|
|
360
|
+
while?: Token;
|
|
361
|
+
endWhile?: Token;
|
|
362
|
+
condition: Expression;
|
|
363
|
+
body: Block;
|
|
364
|
+
});
|
|
303
365
|
readonly tokens: {
|
|
304
|
-
while
|
|
305
|
-
endWhile
|
|
366
|
+
while?: Token;
|
|
367
|
+
endWhile?: Token;
|
|
306
368
|
};
|
|
307
369
|
readonly condition: Expression;
|
|
308
370
|
readonly body: Block;
|
|
309
|
-
constructor(tokens: {
|
|
310
|
-
while: Token;
|
|
311
|
-
endWhile: Token;
|
|
312
|
-
}, condition: Expression, body: Block);
|
|
313
371
|
readonly kind = AstNodeKind.WhileStatement;
|
|
314
372
|
readonly range: Range;
|
|
315
373
|
transpile(state: BrsTranspileState): any[];
|
|
316
374
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
317
375
|
}
|
|
318
376
|
export declare class DottedSetStatement extends Statement {
|
|
377
|
+
constructor(options: {
|
|
378
|
+
obj: Expression;
|
|
379
|
+
name: Identifier;
|
|
380
|
+
value: Expression;
|
|
381
|
+
dot?: Token;
|
|
382
|
+
});
|
|
383
|
+
readonly tokens: {
|
|
384
|
+
name: Identifier;
|
|
385
|
+
dot?: Token;
|
|
386
|
+
};
|
|
319
387
|
readonly obj: Expression;
|
|
320
|
-
readonly name: Identifier;
|
|
321
388
|
readonly value: Expression;
|
|
322
|
-
readonly dot?: Token;
|
|
323
|
-
constructor(obj: Expression, name: Identifier, value: Expression, dot?: Token);
|
|
324
389
|
readonly kind = AstNodeKind.DottedSetStatement;
|
|
325
390
|
readonly range: Range;
|
|
326
391
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
@@ -328,26 +393,34 @@ export declare class DottedSetStatement extends Statement {
|
|
|
328
393
|
getType(options: GetTypeOptions): BscType;
|
|
329
394
|
}
|
|
330
395
|
export declare class IndexedSetStatement extends Statement {
|
|
396
|
+
constructor(options: {
|
|
397
|
+
obj: Expression;
|
|
398
|
+
indexes: Expression[];
|
|
399
|
+
value: Expression;
|
|
400
|
+
openingSquare?: Token;
|
|
401
|
+
closingSquare?: Token;
|
|
402
|
+
});
|
|
403
|
+
readonly tokens: {
|
|
404
|
+
openingSquare?: Token;
|
|
405
|
+
closingSquare?: Token;
|
|
406
|
+
};
|
|
331
407
|
readonly obj: Expression;
|
|
332
|
-
readonly
|
|
408
|
+
readonly indexes: Expression[];
|
|
333
409
|
readonly value: Expression;
|
|
334
|
-
readonly openingSquare: Token;
|
|
335
|
-
readonly closingSquare: Token;
|
|
336
|
-
constructor(obj: Expression, index: Expression, value: Expression, openingSquare: Token, closingSquare: Token);
|
|
337
410
|
readonly kind = AstNodeKind.IndexedSetStatement;
|
|
338
411
|
readonly range: Range;
|
|
339
|
-
transpile(state: BrsTranspileState):
|
|
412
|
+
transpile(state: BrsTranspileState): any[];
|
|
340
413
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
341
414
|
}
|
|
342
415
|
export declare class LibraryStatement extends Statement implements TypedefProvider {
|
|
416
|
+
constructor(options: {
|
|
417
|
+
library: Token;
|
|
418
|
+
filePath?: Token;
|
|
419
|
+
});
|
|
343
420
|
readonly tokens: {
|
|
344
421
|
library: Token;
|
|
345
|
-
filePath
|
|
422
|
+
filePath?: Token;
|
|
346
423
|
};
|
|
347
|
-
constructor(tokens: {
|
|
348
|
-
library: Token;
|
|
349
|
-
filePath: Token | undefined;
|
|
350
|
-
});
|
|
351
424
|
readonly kind = AstNodeKind.LibraryStatement;
|
|
352
425
|
readonly range: Range;
|
|
353
426
|
transpile(state: BrsTranspileState): any[];
|
|
@@ -355,11 +428,18 @@ export declare class LibraryStatement extends Statement implements TypedefProvid
|
|
|
355
428
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
356
429
|
}
|
|
357
430
|
export declare class NamespaceStatement extends Statement implements TypedefProvider {
|
|
358
|
-
|
|
359
|
-
|
|
431
|
+
constructor(options: {
|
|
432
|
+
namespace?: Token;
|
|
433
|
+
nameExpression: VariableExpression | DottedGetExpression;
|
|
434
|
+
body: Body;
|
|
435
|
+
endNamespace?: Token;
|
|
436
|
+
});
|
|
437
|
+
readonly tokens: {
|
|
438
|
+
namespace?: Token;
|
|
439
|
+
endNamespace?: Token;
|
|
440
|
+
};
|
|
441
|
+
readonly nameExpression: VariableExpression | DottedGetExpression;
|
|
360
442
|
body: Body;
|
|
361
|
-
endKeyword: Token;
|
|
362
|
-
constructor(keyword: Token, nameExpression: VariableExpression | DottedGetExpression, body: Body, endKeyword: Token);
|
|
363
443
|
readonly kind = AstNodeKind.NamespaceStatement;
|
|
364
444
|
/**
|
|
365
445
|
* The string name for this namespace
|
|
@@ -377,9 +457,14 @@ export declare class NamespaceStatement extends Statement implements TypedefProv
|
|
|
377
457
|
getType(options: GetTypeOptions): NamespaceType;
|
|
378
458
|
}
|
|
379
459
|
export declare class ImportStatement extends Statement implements TypedefProvider {
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
460
|
+
constructor(options: {
|
|
461
|
+
import?: Token;
|
|
462
|
+
filePath: Token;
|
|
463
|
+
});
|
|
464
|
+
readonly tokens: {
|
|
465
|
+
import?: Token;
|
|
466
|
+
filePath: Token;
|
|
467
|
+
};
|
|
383
468
|
readonly kind = AstNodeKind.ImportStatement;
|
|
384
469
|
range: Range;
|
|
385
470
|
filePath: string;
|
|
@@ -391,15 +476,22 @@ export declare class ImportStatement extends Statement implements TypedefProvide
|
|
|
391
476
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
392
477
|
}
|
|
393
478
|
export declare class InterfaceStatement extends Statement implements TypedefProvider {
|
|
394
|
-
|
|
479
|
+
constructor(options: {
|
|
480
|
+
interface: Token;
|
|
481
|
+
name: Identifier;
|
|
482
|
+
extends?: Token;
|
|
483
|
+
parentInterfaceName?: TypeExpression;
|
|
484
|
+
body: Statement[];
|
|
485
|
+
endInterface?: Token;
|
|
486
|
+
});
|
|
487
|
+
parentInterfaceName?: TypeExpression;
|
|
395
488
|
body: Statement[];
|
|
396
|
-
constructor(interfaceToken: Token, name: Identifier, extendsToken: Token, parentInterfaceName: TypeExpression, body: Statement[], endInterfaceToken: Token);
|
|
397
489
|
readonly kind = AstNodeKind.InterfaceStatement;
|
|
398
490
|
tokens: {
|
|
399
|
-
interface
|
|
491
|
+
interface?: Token;
|
|
400
492
|
name: Identifier;
|
|
401
|
-
extends
|
|
402
|
-
endInterface
|
|
493
|
+
extends?: Token;
|
|
494
|
+
endInterface?: Token;
|
|
403
495
|
};
|
|
404
496
|
range: Range;
|
|
405
497
|
get fields(): InterfaceFieldStatement[];
|
|
@@ -424,10 +516,15 @@ export declare class InterfaceStatement extends Statement implements TypedefProv
|
|
|
424
516
|
getType(options: GetTypeOptions): InterfaceType;
|
|
425
517
|
}
|
|
426
518
|
export declare class InterfaceFieldStatement extends Statement implements TypedefProvider {
|
|
427
|
-
typeExpression?: TypeExpression;
|
|
428
519
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
429
|
-
constructor(
|
|
520
|
+
constructor(options: {
|
|
521
|
+
name: Identifier;
|
|
522
|
+
as?: Token;
|
|
523
|
+
typeExpression?: TypeExpression;
|
|
524
|
+
optional?: Token;
|
|
525
|
+
});
|
|
430
526
|
readonly kind = AstNodeKind.InterfaceFieldStatement;
|
|
527
|
+
typeExpression?: TypeExpression;
|
|
431
528
|
range: Range;
|
|
432
529
|
tokens: {
|
|
433
530
|
name: Identifier;
|
|
@@ -442,10 +539,17 @@ export declare class InterfaceFieldStatement extends Statement implements Typede
|
|
|
442
539
|
getType(options: GetTypeOptions): BscType;
|
|
443
540
|
}
|
|
444
541
|
export declare class InterfaceMethodStatement extends Statement implements TypedefProvider {
|
|
445
|
-
params: FunctionParameterExpression[];
|
|
446
|
-
returnTypeExpression?: TypeExpression;
|
|
447
542
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
448
|
-
constructor(
|
|
543
|
+
constructor(options: {
|
|
544
|
+
functionType?: Token;
|
|
545
|
+
name: Identifier;
|
|
546
|
+
leftParen?: Token;
|
|
547
|
+
params?: FunctionParameterExpression[];
|
|
548
|
+
rightParen?: Token;
|
|
549
|
+
as?: Token;
|
|
550
|
+
returnTypeExpression?: TypeExpression;
|
|
551
|
+
optional?: Token;
|
|
552
|
+
});
|
|
449
553
|
readonly kind = AstNodeKind.InterfaceMethodStatement;
|
|
450
554
|
get range(): Range;
|
|
451
555
|
/**
|
|
@@ -456,10 +560,12 @@ export declare class InterfaceMethodStatement extends Statement implements Typed
|
|
|
456
560
|
optional?: Token;
|
|
457
561
|
functionType: Token;
|
|
458
562
|
name: Identifier;
|
|
459
|
-
leftParen
|
|
460
|
-
rightParen
|
|
461
|
-
as
|
|
563
|
+
leftParen?: Token;
|
|
564
|
+
rightParen?: Token;
|
|
565
|
+
as?: Token;
|
|
462
566
|
};
|
|
567
|
+
params: FunctionParameterExpression[];
|
|
568
|
+
returnTypeExpression?: TypeExpression;
|
|
463
569
|
get isOptional(): boolean;
|
|
464
570
|
getLeadingTrivia(): Token[];
|
|
465
571
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
@@ -467,21 +573,29 @@ export declare class InterfaceMethodStatement extends Statement implements Typed
|
|
|
467
573
|
getType(options: GetTypeOptions): TypedFunctionType;
|
|
468
574
|
}
|
|
469
575
|
export declare class ClassStatement extends Statement implements TypedefProvider {
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
* The name of the class (without namespace prefix)
|
|
482
|
-
*/
|
|
483
|
-
name: Identifier, body: Statement[], end: Token, extendsKeyword?: Token, parentClassName?: TypeExpression);
|
|
576
|
+
constructor(options: {
|
|
577
|
+
class?: Token;
|
|
578
|
+
/**
|
|
579
|
+
* The name of the class (without namespace prefix)
|
|
580
|
+
*/
|
|
581
|
+
name: Identifier;
|
|
582
|
+
body: Statement[];
|
|
583
|
+
endClass?: Token;
|
|
584
|
+
extends?: Token;
|
|
585
|
+
parentClassName?: TypeExpression;
|
|
586
|
+
});
|
|
484
587
|
readonly kind = AstNodeKind.ClassStatement;
|
|
588
|
+
tokens: {
|
|
589
|
+
class?: Token;
|
|
590
|
+
/**
|
|
591
|
+
* The name of the class (without namespace prefix)
|
|
592
|
+
*/
|
|
593
|
+
name: Identifier;
|
|
594
|
+
endClass?: Token;
|
|
595
|
+
extends?: Token;
|
|
596
|
+
};
|
|
597
|
+
readonly body: Statement[];
|
|
598
|
+
readonly parentClassName: TypeExpression;
|
|
485
599
|
getName(parseMode: ParseMode): string;
|
|
486
600
|
getLeadingTrivia(): Token[];
|
|
487
601
|
memberMap: Record<string, MemberStatement>;
|
|
@@ -528,10 +642,18 @@ export declare class ClassStatement extends Statement implements TypedefProvider
|
|
|
528
642
|
getType(options: GetTypeOptions): ClassType;
|
|
529
643
|
}
|
|
530
644
|
export declare class MethodStatement extends FunctionStatement {
|
|
531
|
-
|
|
532
|
-
|
|
645
|
+
constructor(options: {
|
|
646
|
+
modifiers?: Token | Token[];
|
|
647
|
+
name: Identifier;
|
|
648
|
+
func: FunctionExpression;
|
|
649
|
+
override?: Token;
|
|
650
|
+
});
|
|
533
651
|
readonly kind: AstNodeKind;
|
|
534
652
|
modifiers: Token[];
|
|
653
|
+
readonly tokens: {
|
|
654
|
+
name: Identifier;
|
|
655
|
+
override?: Token;
|
|
656
|
+
};
|
|
535
657
|
get accessModifier(): Token;
|
|
536
658
|
readonly range: Range;
|
|
537
659
|
/**
|
|
@@ -553,14 +675,24 @@ export declare class MethodStatement extends FunctionStatement {
|
|
|
553
675
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
554
676
|
}
|
|
555
677
|
export declare class FieldStatement extends Statement implements TypedefProvider {
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
678
|
+
constructor(options: {
|
|
679
|
+
accessModifier?: Token;
|
|
680
|
+
name: Identifier;
|
|
681
|
+
as?: Token;
|
|
682
|
+
typeExpression?: TypeExpression;
|
|
683
|
+
equals?: Token;
|
|
684
|
+
initialValue?: Expression;
|
|
685
|
+
optional?: Token;
|
|
686
|
+
});
|
|
687
|
+
readonly tokens: {
|
|
688
|
+
accessModifier?: Token;
|
|
689
|
+
name: Identifier;
|
|
690
|
+
as?: Token;
|
|
691
|
+
equals?: Token;
|
|
692
|
+
optional?: Token;
|
|
693
|
+
};
|
|
694
|
+
typeExpression?: TypeExpression;
|
|
695
|
+
initialValue?: Expression;
|
|
564
696
|
readonly kind = AstNodeKind.FieldStatement;
|
|
565
697
|
/**
|
|
566
698
|
* Derive a ValueKind from the type token, or the initial value.
|
|
@@ -576,56 +708,66 @@ export declare class FieldStatement extends Statement implements TypedefProvider
|
|
|
576
708
|
}
|
|
577
709
|
export declare type MemberStatement = FieldStatement | MethodStatement;
|
|
578
710
|
export declare class TryCatchStatement extends Statement {
|
|
579
|
-
|
|
580
|
-
try
|
|
711
|
+
constructor(options?: {
|
|
712
|
+
try?: Token;
|
|
581
713
|
endTry?: Token;
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
try
|
|
714
|
+
tryBranch?: Block;
|
|
715
|
+
catchStatement?: CatchStatement;
|
|
716
|
+
});
|
|
717
|
+
readonly tokens: {
|
|
718
|
+
try?: Token;
|
|
587
719
|
endTry?: Token;
|
|
588
|
-
}
|
|
720
|
+
};
|
|
721
|
+
tryBranch: Block;
|
|
722
|
+
catchStatement: CatchStatement;
|
|
589
723
|
readonly kind = AstNodeKind.TryCatchStatement;
|
|
590
724
|
readonly range: Range;
|
|
591
725
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
592
726
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
593
727
|
}
|
|
594
728
|
export declare class CatchStatement extends Statement {
|
|
595
|
-
|
|
596
|
-
catch
|
|
729
|
+
constructor(options?: {
|
|
730
|
+
catch?: Token;
|
|
731
|
+
exceptionVariable?: Identifier;
|
|
732
|
+
catchBranch?: Block;
|
|
733
|
+
});
|
|
734
|
+
readonly tokens: {
|
|
735
|
+
catch?: Token;
|
|
736
|
+
exceptionVariable?: Identifier;
|
|
597
737
|
};
|
|
598
|
-
exceptionVariable?: Identifier;
|
|
599
738
|
catchBranch?: Block;
|
|
600
|
-
constructor(tokens: {
|
|
601
|
-
catch: Token;
|
|
602
|
-
}, exceptionVariable?: Identifier, catchBranch?: Block);
|
|
603
739
|
readonly kind = AstNodeKind.CatchStatement;
|
|
604
740
|
range: Range;
|
|
605
741
|
transpile(state: BrsTranspileState): TranspileResult;
|
|
606
742
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
607
743
|
}
|
|
608
744
|
export declare class ThrowStatement extends Statement {
|
|
609
|
-
|
|
745
|
+
constructor(options?: {
|
|
746
|
+
throw?: Token;
|
|
747
|
+
expression?: Expression;
|
|
748
|
+
});
|
|
749
|
+
readonly tokens: {
|
|
750
|
+
throw?: Token;
|
|
751
|
+
};
|
|
610
752
|
expression?: Expression;
|
|
611
|
-
constructor(throwToken: Token, expression?: Expression);
|
|
612
753
|
readonly kind = AstNodeKind.ThrowStatement;
|
|
613
754
|
range: Range;
|
|
614
755
|
transpile(state: BrsTranspileState): (string | SourceNode)[];
|
|
615
756
|
walk(visitor: WalkVisitor, options: WalkOptions): void;
|
|
616
757
|
}
|
|
617
758
|
export declare class EnumStatement extends Statement implements TypedefProvider {
|
|
759
|
+
constructor(options: {
|
|
760
|
+
enum?: Token;
|
|
761
|
+
name: Identifier;
|
|
762
|
+
endEnum?: Token;
|
|
763
|
+
body: Array<EnumMemberStatement | CommentStatement>;
|
|
764
|
+
});
|
|
618
765
|
tokens: {
|
|
619
|
-
enum
|
|
766
|
+
enum?: Token;
|
|
620
767
|
name: Identifier;
|
|
621
|
-
endEnum
|
|
768
|
+
endEnum?: Token;
|
|
622
769
|
};
|
|
623
770
|
body: Array<EnumMemberStatement | CommentStatement>;
|
|
624
|
-
constructor(tokens: {
|
|
625
|
-
enum: Token;
|
|
626
|
-
name: Identifier;
|
|
627
|
-
endEnum: Token;
|
|
628
|
-
}, body: Array<EnumMemberStatement | CommentStatement>);
|
|
629
771
|
readonly kind = AstNodeKind.EnumStatement;
|
|
630
772
|
symbolTable: SymbolTable;
|
|
631
773
|
get range(): Range;
|
|
@@ -651,15 +793,16 @@ export declare class EnumStatement extends Statement implements TypedefProvider
|
|
|
651
793
|
getType(options: GetTypeOptions): EnumType;
|
|
652
794
|
}
|
|
653
795
|
export declare class EnumMemberStatement extends Statement implements TypedefProvider {
|
|
796
|
+
constructor(options: {
|
|
797
|
+
name: Identifier;
|
|
798
|
+
equals?: Token;
|
|
799
|
+
value?: Expression;
|
|
800
|
+
});
|
|
654
801
|
tokens: {
|
|
655
802
|
name: Identifier;
|
|
656
|
-
|
|
803
|
+
equals?: Token;
|
|
657
804
|
};
|
|
658
805
|
value?: Expression;
|
|
659
|
-
constructor(tokens: {
|
|
660
|
-
name: Identifier;
|
|
661
|
-
equal?: Token;
|
|
662
|
-
}, value?: Expression);
|
|
663
806
|
readonly kind = AstNodeKind.EnumMemberStatement;
|
|
664
807
|
get range(): Range;
|
|
665
808
|
/**
|
|
@@ -673,17 +816,18 @@ export declare class EnumMemberStatement extends Statement implements TypedefPro
|
|
|
673
816
|
getType(options: GetTypeOptions): EnumMemberType;
|
|
674
817
|
}
|
|
675
818
|
export declare class ConstStatement extends Statement implements TypedefProvider {
|
|
819
|
+
constructor(options: {
|
|
820
|
+
const?: Token;
|
|
821
|
+
name: Identifier;
|
|
822
|
+
equals?: Token;
|
|
823
|
+
value: Expression;
|
|
824
|
+
});
|
|
676
825
|
tokens: {
|
|
677
826
|
const: Token;
|
|
678
827
|
name: Identifier;
|
|
679
828
|
equals: Token;
|
|
680
829
|
};
|
|
681
830
|
value: Expression;
|
|
682
|
-
constructor(tokens: {
|
|
683
|
-
const: Token;
|
|
684
|
-
name: Identifier;
|
|
685
|
-
equals: Token;
|
|
686
|
-
}, value: Expression);
|
|
687
831
|
readonly kind = AstNodeKind.ConstStatement;
|
|
688
832
|
range: Range;
|
|
689
833
|
get name(): string;
|
|
@@ -698,14 +842,14 @@ export declare class ConstStatement extends Statement implements TypedefProvider
|
|
|
698
842
|
getType(options: GetTypeOptions): BscType;
|
|
699
843
|
}
|
|
700
844
|
export declare class ContinueStatement extends Statement {
|
|
845
|
+
constructor(options: {
|
|
846
|
+
continue?: Token;
|
|
847
|
+
loopType: Token;
|
|
848
|
+
});
|
|
701
849
|
tokens: {
|
|
702
|
-
continue
|
|
850
|
+
continue?: Token;
|
|
703
851
|
loopType: Token;
|
|
704
852
|
};
|
|
705
|
-
constructor(tokens: {
|
|
706
|
-
continue: Token;
|
|
707
|
-
loopType: Token;
|
|
708
|
-
});
|
|
709
853
|
readonly kind = AstNodeKind.ContinueStatement;
|
|
710
854
|
range: Range;
|
|
711
855
|
transpile(state: BrsTranspileState): (string | SourceNode)[];
|