brighterscript 0.66.0-alpha.6 → 0.66.0-alpha.8
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 +88 -10
- package/README.md +16 -0
- package/bsconfig.schema.json +15 -0
- package/dist/ActionPipeline.d.ts +10 -0
- package/dist/ActionPipeline.js +40 -0
- package/dist/ActionPipeline.js.map +1 -0
- package/dist/AstValidationSegmenter.d.ts +25 -0
- package/dist/AstValidationSegmenter.js +150 -0
- package/dist/AstValidationSegmenter.js.map +1 -0
- package/dist/BsConfig.d.ts +15 -1
- package/dist/CommentFlagProcessor.d.ts +4 -3
- package/dist/CommentFlagProcessor.js.map +1 -1
- package/dist/DiagnosticMessages.d.ts +8 -1
- package/dist/DiagnosticMessages.js +30 -13
- package/dist/DiagnosticMessages.js.map +1 -1
- package/dist/LanguageServer.js +7 -1
- package/dist/LanguageServer.js.map +1 -1
- package/dist/PluginInterface.d.ts +11 -2
- package/dist/PluginInterface.js +69 -10
- package/dist/PluginInterface.js.map +1 -1
- package/dist/Program.d.ts +107 -38
- package/dist/Program.js +502 -270
- package/dist/Program.js.map +1 -1
- package/dist/ProgramBuilder.d.ts +10 -4
- package/dist/ProgramBuilder.js +44 -54
- package/dist/ProgramBuilder.js.map +1 -1
- package/dist/Scope.d.ts +26 -38
- package/dist/Scope.js +153 -174
- package/dist/Scope.js.map +1 -1
- package/dist/SymbolTable.d.ts +4 -1
- package/dist/SymbolTable.js +19 -7
- package/dist/SymbolTable.js.map +1 -1
- package/dist/XmlScope.d.ts +5 -4
- package/dist/XmlScope.js +16 -14
- package/dist/XmlScope.js.map +1 -1
- package/dist/astUtils/{AstEditor.d.ts → Editor.d.ts} +6 -1
- package/dist/astUtils/{AstEditor.js → Editor.js} +9 -3
- package/dist/astUtils/Editor.js.map +1 -0
- package/dist/astUtils/{AstEditor.spec.js → Editor.spec.js} +10 -6
- package/dist/astUtils/Editor.spec.js.map +1 -0
- package/dist/astUtils/reflection.d.ts +9 -4
- package/dist/astUtils/reflection.js +23 -7
- package/dist/astUtils/reflection.js.map +1 -1
- package/dist/astUtils/reflection.spec.js +2 -2
- package/dist/astUtils/reflection.spec.js.map +1 -1
- package/dist/astUtils/visitors.d.ts +14 -3
- package/dist/astUtils/visitors.js +22 -2
- package/dist/astUtils/visitors.js.map +1 -1
- package/dist/astUtils/visitors.spec.js +58 -7
- package/dist/astUtils/visitors.spec.js.map +1 -1
- package/dist/bscPlugin/BscPlugin.d.ts +10 -2
- package/dist/bscPlugin/BscPlugin.js +24 -4
- package/dist/bscPlugin/BscPlugin.js.map +1 -1
- package/dist/bscPlugin/FileWriter.d.ts +6 -0
- package/dist/bscPlugin/FileWriter.js +24 -0
- package/dist/bscPlugin/FileWriter.js.map +1 -0
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.js +8 -8
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.js.map +1 -1
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.spec.js.map +1 -1
- package/dist/bscPlugin/completions/CompletionsProcessor.d.ts +7 -2
- package/dist/bscPlugin/completions/CompletionsProcessor.js +112 -44
- package/dist/bscPlugin/completions/CompletionsProcessor.js.map +1 -1
- package/dist/bscPlugin/completions/CompletionsProcessor.spec.js +212 -6
- package/dist/bscPlugin/completions/CompletionsProcessor.spec.js.map +1 -1
- package/dist/bscPlugin/fileProviders/FileProvider.d.ts +9 -0
- package/dist/bscPlugin/fileProviders/FileProvider.js +51 -0
- package/dist/bscPlugin/fileProviders/FileProvider.js.map +1 -0
- package/dist/bscPlugin/hover/HoverProcessor.d.ts +1 -7
- package/dist/bscPlugin/hover/HoverProcessor.js +10 -8
- package/dist/bscPlugin/hover/HoverProcessor.js.map +1 -1
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.d.ts +1 -0
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.js +43 -0
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.js.map +1 -1
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.spec.js +22 -0
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.spec.js.map +1 -1
- package/dist/bscPlugin/serialize/BslibInjector.spec.js +19 -0
- package/dist/bscPlugin/serialize/BslibInjector.spec.js.map +1 -0
- package/dist/bscPlugin/serialize/BslibManager.d.ts +9 -0
- package/dist/bscPlugin/serialize/BslibManager.js +40 -0
- package/dist/bscPlugin/serialize/BslibManager.js.map +1 -0
- package/dist/bscPlugin/serialize/FileSerializer.d.ts +9 -0
- package/dist/bscPlugin/serialize/FileSerializer.js +72 -0
- package/dist/bscPlugin/serialize/FileSerializer.js.map +1 -0
- package/dist/bscPlugin/transpile/{BrsFilePreTranspileProcessor.d.ts → BrsFileTranspileProcessor.d.ts} +4 -2
- package/dist/bscPlugin/transpile/{BrsFilePreTranspileProcessor.js → BrsFileTranspileProcessor.js} +29 -5
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.js.map +1 -0
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.spec.d.ts +1 -0
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.spec.js +41 -0
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.spec.js.map +1 -0
- package/dist/bscPlugin/transpile/XmlFilePreTranspileProcessor.d.ts +2 -2
- package/dist/bscPlugin/transpile/XmlFilePreTranspileProcessor.js.map +1 -1
- package/dist/bscPlugin/validation/BrsFileValidator.js +8 -3
- package/dist/bscPlugin/validation/BrsFileValidator.js.map +1 -1
- package/dist/bscPlugin/validation/BrsFileValidator.spec.js +1 -1
- package/dist/bscPlugin/validation/BrsFileValidator.spec.js.map +1 -1
- package/dist/bscPlugin/validation/ScopeValidator.d.ts +5 -9
- package/dist/bscPlugin/validation/ScopeValidator.js +214 -222
- package/dist/bscPlugin/validation/ScopeValidator.js.map +1 -1
- package/dist/bscPlugin/validation/ScopeValidator.spec.js +669 -0
- package/dist/bscPlugin/validation/ScopeValidator.spec.js.map +1 -1
- package/dist/bscPlugin/validation/XmlFileValidator.js +2 -2
- package/dist/bscPlugin/validation/XmlFileValidator.js.map +1 -1
- package/dist/cli.js +1 -0
- package/dist/cli.js.map +1 -1
- package/dist/deferred.d.ts +2 -2
- package/dist/deferred.js.map +1 -1
- package/dist/diagnosticUtils.d.ts +1 -0
- package/dist/diagnosticUtils.js +4 -3
- package/dist/diagnosticUtils.js.map +1 -1
- package/dist/examples/plugins/removePrint.js +1 -1
- package/dist/examples/plugins/removePrint.js.map +1 -1
- package/dist/files/AssetFile.d.ts +26 -0
- package/dist/files/AssetFile.js +26 -0
- package/dist/files/AssetFile.js.map +1 -0
- package/dist/files/BrsFile.Class.spec.js +241 -40
- package/dist/files/BrsFile.Class.spec.js.map +1 -1
- package/dist/files/BrsFile.d.ts +66 -16
- package/dist/files/BrsFile.js +330 -80
- package/dist/files/BrsFile.js.map +1 -1
- package/dist/files/BrsFile.spec.js +1134 -167
- package/dist/files/BrsFile.spec.js.map +1 -1
- package/dist/files/Factory.d.ts +25 -0
- package/dist/files/Factory.js +22 -0
- package/dist/files/Factory.js.map +1 -0
- package/dist/files/File.d.ts +106 -0
- package/dist/files/File.js +16 -0
- package/dist/files/File.js.map +1 -0
- package/dist/files/LazyFileData.d.ts +20 -0
- package/dist/files/LazyFileData.js +54 -0
- package/dist/files/LazyFileData.js.map +1 -0
- package/dist/files/LazyFileData.spec.d.ts +1 -0
- package/dist/files/LazyFileData.spec.js +27 -0
- package/dist/files/LazyFileData.spec.js.map +1 -0
- package/dist/files/XmlFile.d.ts +55 -17
- package/dist/files/XmlFile.js +88 -47
- package/dist/files/XmlFile.js.map +1 -1
- package/dist/files/XmlFile.spec.js +64 -57
- package/dist/files/XmlFile.spec.js.map +1 -1
- package/dist/files/tests/imports.spec.js +21 -8
- package/dist/files/tests/imports.spec.js.map +1 -1
- package/dist/files/tests/optionalChaning.spec.js +14 -14
- package/dist/files/tests/optionalChaning.spec.js.map +1 -1
- package/dist/globalCallables.js +1 -1
- package/dist/globalCallables.js.map +1 -1
- package/dist/index.d.ts +6 -1
- package/dist/index.js +6 -1
- package/dist/index.js.map +1 -1
- package/dist/interfaces.d.ts +357 -89
- package/dist/interfaces.js +10 -2
- package/dist/interfaces.js.map +1 -1
- package/dist/lexer/Lexer.js +1 -1
- package/dist/lexer/TokenKind.d.ts +1 -0
- package/dist/lexer/TokenKind.js +4 -1
- package/dist/lexer/TokenKind.js.map +1 -1
- package/dist/parser/AstNode.d.ts +2 -2
- package/dist/parser/AstNode.js +1 -1
- package/dist/parser/AstNode.js.map +1 -1
- package/dist/parser/BrsTranspileState.d.ts +3 -2
- package/dist/parser/BrsTranspileState.js +3 -2
- package/dist/parser/BrsTranspileState.js.map +1 -1
- package/dist/parser/Expression.d.ts +2 -2
- package/dist/parser/Expression.js +23 -19
- package/dist/parser/Expression.js.map +1 -1
- package/dist/parser/Parser.Class.spec.js +103 -0
- package/dist/parser/Parser.Class.spec.js.map +1 -1
- package/dist/parser/Parser.js +61 -13
- package/dist/parser/Parser.js.map +1 -1
- package/dist/parser/Parser.spec.js +227 -1
- package/dist/parser/Parser.spec.js.map +1 -1
- package/dist/parser/SGParser.d.ts +2 -2
- package/dist/parser/SGParser.js +3 -3
- package/dist/parser/SGParser.js.map +1 -1
- package/dist/parser/SGParser.spec.js +2 -2
- package/dist/parser/SGParser.spec.js.map +1 -1
- package/dist/parser/SGTypes.d.ts +1 -1
- package/dist/parser/Statement.d.ts +12 -5
- package/dist/parser/Statement.js +56 -26
- package/dist/parser/Statement.js.map +1 -1
- package/dist/parser/tests/expression/NullCoalescenceExpression.spec.js +16 -16
- package/dist/parser/tests/expression/NullCoalescenceExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/RegexLiteralExpression.spec.js +10 -10
- package/dist/parser/tests/expression/RegexLiteralExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/SourceLiteralExpression.spec.js +24 -24
- package/dist/parser/tests/expression/SourceLiteralExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/TemplateStringExpression.spec.js +64 -36
- package/dist/parser/tests/expression/TemplateStringExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/TernaryExpression.spec.js +34 -34
- package/dist/parser/tests/expression/TernaryExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/UnaryExpression.spec.d.ts +1 -0
- package/dist/parser/tests/expression/UnaryExpression.spec.js +52 -0
- package/dist/parser/tests/expression/UnaryExpression.spec.js.map +1 -0
- package/dist/parser/tests/statement/ConstStatement.spec.js +90 -16
- package/dist/parser/tests/statement/ConstStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/Continue.spec.js +2 -2
- package/dist/parser/tests/statement/Continue.spec.js.map +1 -1
- package/dist/parser/tests/statement/Enum.spec.js +35 -26
- package/dist/parser/tests/statement/Enum.spec.js.map +1 -1
- package/dist/parser/tests/statement/For.spec.js +6 -6
- package/dist/parser/tests/statement/For.spec.js.map +1 -1
- package/dist/parser/tests/statement/ForEach.spec.js +4 -4
- package/dist/parser/tests/statement/ForEach.spec.js.map +1 -1
- package/dist/parser/tests/statement/InterfaceStatement.spec.js +20 -12
- package/dist/parser/tests/statement/InterfaceStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/PrintStatement.spec.js +10 -10
- package/dist/parser/tests/statement/PrintStatement.spec.js.map +1 -1
- package/dist/preprocessor/Manifest.d.ts +1 -1
- package/dist/preprocessor/Manifest.js +2 -2
- package/dist/preprocessor/Manifest.js.map +1 -1
- package/dist/roku-types/data.json +98 -193
- package/dist/roku-types/index.d.ts +15 -11
- package/dist/types/ArrayType.d.ts +1 -1
- package/dist/types/ArrayType.js +4 -0
- package/dist/types/ArrayType.js.map +1 -1
- package/dist/types/ArrayType.spec.js +1 -1
- package/dist/types/ArrayType.spec.js.map +1 -1
- package/dist/types/AssociativeArrayType.d.ts +1 -1
- package/dist/types/AssociativeArrayType.js +1 -1
- package/dist/types/AssociativeArrayType.js.map +1 -1
- package/dist/types/BooleanType.d.ts +1 -1
- package/dist/types/BooleanType.js +2 -1
- package/dist/types/BooleanType.js.map +1 -1
- package/dist/types/BscType.d.ts +2 -2
- package/dist/types/BscType.js +30 -9
- package/dist/types/BscType.js.map +1 -1
- package/dist/types/BuiltInInterfaceAdder.d.ts +3 -0
- package/dist/types/BuiltInInterfaceAdder.js +37 -16
- package/dist/types/BuiltInInterfaceAdder.js.map +1 -1
- package/dist/types/BuiltInInterfaceAdder.spec.js +7 -0
- package/dist/types/BuiltInInterfaceAdder.spec.js.map +1 -1
- package/dist/types/ClassType.d.ts +4 -3
- package/dist/types/ClassType.js +6 -3
- package/dist/types/ClassType.js.map +1 -1
- package/dist/types/ClassType.spec.js +5 -3
- package/dist/types/ClassType.spec.js.map +1 -1
- package/dist/types/ComponentType.d.ts +1 -1
- package/dist/types/ComponentType.js +3 -0
- package/dist/types/ComponentType.js.map +1 -1
- package/dist/types/DoubleType.js +3 -1
- package/dist/types/DoubleType.js.map +1 -1
- package/dist/types/EnumType.d.ts +1 -1
- package/dist/types/EnumType.js +7 -2
- package/dist/types/EnumType.js.map +1 -1
- package/dist/types/FloatType.js +3 -1
- package/dist/types/FloatType.js.map +1 -1
- package/dist/types/InheritableType.d.ts +7 -4
- package/dist/types/InheritableType.js +67 -3
- package/dist/types/InheritableType.js.map +1 -1
- package/dist/types/IntegerType.js +3 -1
- package/dist/types/IntegerType.js.map +1 -1
- package/dist/types/InterfaceType.d.ts +5 -4
- package/dist/types/InterfaceType.js +5 -12
- package/dist/types/InterfaceType.js.map +1 -1
- package/dist/types/InterfaceType.spec.js +23 -0
- package/dist/types/InterfaceType.spec.js.map +1 -1
- package/dist/types/LongIntegerType.js +3 -1
- package/dist/types/LongIntegerType.js.map +1 -1
- package/dist/types/NamespaceType.d.ts +2 -1
- package/dist/types/NamespaceType.js +3 -0
- package/dist/types/NamespaceType.js.map +1 -1
- package/dist/types/ObjectType.d.ts +1 -1
- package/dist/types/ReferenceType.js +40 -6
- package/dist/types/ReferenceType.js.map +1 -1
- package/dist/types/StringType.js +2 -2
- package/dist/types/StringType.js.map +1 -1
- package/dist/types/TypedFunctionType.d.ts +6 -1
- package/dist/types/TypedFunctionType.js +46 -16
- package/dist/types/TypedFunctionType.js.map +1 -1
- package/dist/types/TypedFunctionType.spec.js +99 -0
- package/dist/types/TypedFunctionType.spec.js.map +1 -1
- package/dist/types/UnionType.js +8 -0
- package/dist/types/UnionType.js.map +1 -1
- package/dist/types/helper.spec.js +15 -0
- package/dist/types/helper.spec.js.map +1 -1
- package/dist/types/helpers.d.ts +3 -0
- package/dist/types/helpers.js +33 -1
- package/dist/types/helpers.js.map +1 -1
- package/dist/util.d.ts +25 -9
- package/dist/util.js +165 -72
- package/dist/util.js.map +1 -1
- package/dist/validators/ClassValidator.js.map +1 -1
- package/package.json +2 -2
- package/dist/astUtils/AstEditor.js.map +0 -1
- package/dist/astUtils/AstEditor.spec.js.map +0 -1
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.js.map +0 -1
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.spec.js +0 -31
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.spec.js.map +0 -1
- /package/dist/astUtils/{AstEditor.spec.d.ts → Editor.spec.d.ts} +0 -0
- /package/dist/bscPlugin/{transpile/BrsFilePreTranspileProcessor.spec.d.ts → serialize/BslibInjector.spec.d.ts} +0 -0
package/dist/files/BrsFile.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { CodeWithSourceMap } from 'source-map';
|
|
|
2
2
|
import type { CompletionItem, Position, Location, Diagnostic } from 'vscode-languageserver';
|
|
3
3
|
import { DocumentSymbol, SymbolInformation } from 'vscode-languageserver';
|
|
4
4
|
import { FunctionScope } from '../FunctionScope';
|
|
5
|
-
import type { Callable, CommentFlag, FunctionCall, BsDiagnostic, FileReference, FileLink,
|
|
5
|
+
import type { Callable, CommentFlag, FunctionCall, BsDiagnostic, FileReference, FileLink, SerializedCodeFile, NamespaceContainer } from '../interfaces';
|
|
6
6
|
import type { Token } from '../lexer/Token';
|
|
7
7
|
import { TokenKind } from '../lexer/TokenKind';
|
|
8
8
|
import { Parser, ParseMode } from '../parser/Parser';
|
|
@@ -10,28 +10,54 @@ import type { FunctionExpression } from '../parser/Expression';
|
|
|
10
10
|
import type { ClassStatement, NamespaceStatement, MethodStatement } from '../parser/Statement';
|
|
11
11
|
import type { Program } from '../Program';
|
|
12
12
|
import type { DependencyGraph } from '../DependencyGraph';
|
|
13
|
-
import {
|
|
13
|
+
import type { AstNode } from '../parser/AstNode';
|
|
14
|
+
import { type Expression } from '../parser/AstNode';
|
|
15
|
+
import type { BscSymbol } from '../SymbolTable';
|
|
16
|
+
import { SymbolTypeFlag } from '../SymbolTable';
|
|
17
|
+
import type { File } from './File';
|
|
18
|
+
import { Editor } from '../astUtils/Editor';
|
|
19
|
+
import type { UnresolvedSymbol } from '../AstValidationSegmenter';
|
|
20
|
+
import { AstValidationSegmenter } from '../AstValidationSegmenter';
|
|
21
|
+
export declare type ProvidedSymbolMap = Map<SymbolTypeFlag, Map<string, BscSymbol>>;
|
|
22
|
+
export declare type ChangedSymbolMap = Map<SymbolTypeFlag, Set<string>>;
|
|
23
|
+
export interface ProvidedSymbolInfo {
|
|
24
|
+
symbolMap: ProvidedSymbolMap;
|
|
25
|
+
changes: ChangedSymbolMap;
|
|
26
|
+
}
|
|
14
27
|
/**
|
|
15
28
|
* Holds all details about this file within the scope of the whole program
|
|
16
29
|
*/
|
|
17
|
-
export declare class BrsFile {
|
|
30
|
+
export declare class BrsFile implements File {
|
|
31
|
+
constructor(options: {
|
|
32
|
+
/**
|
|
33
|
+
* The path to the file in its source location (where the source code lives in the file system)
|
|
34
|
+
*/
|
|
35
|
+
srcPath: string;
|
|
36
|
+
/**
|
|
37
|
+
* The path to the file where it should exist in the program. This is similar to pkgPath, but retains its original file extensions from srcPath
|
|
38
|
+
*/
|
|
39
|
+
destPath: string;
|
|
40
|
+
/**
|
|
41
|
+
* The final path in the zip. This has the extensions changed. Typically this is the same as destPath, but with file extensions changed for transpiled files.
|
|
42
|
+
*/
|
|
43
|
+
pkgPath?: string;
|
|
44
|
+
program: Program;
|
|
45
|
+
});
|
|
46
|
+
type: string;
|
|
18
47
|
srcPath: string;
|
|
19
|
-
|
|
20
|
-
* The full pkg path to this file
|
|
21
|
-
*/
|
|
48
|
+
destPath: string;
|
|
22
49
|
pkgPath: string;
|
|
23
50
|
program: Program;
|
|
24
|
-
constructor(srcPath: string,
|
|
25
51
|
/**
|
|
26
|
-
*
|
|
52
|
+
* An editor assigned during the build flow that manages edits that will be undone once the build process is complete.
|
|
27
53
|
*/
|
|
28
|
-
|
|
54
|
+
editor?: Editor;
|
|
29
55
|
/**
|
|
30
56
|
* The parseMode used for the parser for this file
|
|
31
57
|
*/
|
|
32
58
|
parseMode: ParseMode;
|
|
33
59
|
/**
|
|
34
|
-
* The key used to identify this file in the dependency graph
|
|
60
|
+
* The key used to identify this file in the dependency graph. This is set by the BrighterScript program and should not be set by plugins
|
|
35
61
|
*/
|
|
36
62
|
dependencyGraphKey: string;
|
|
37
63
|
/**
|
|
@@ -47,9 +73,12 @@ export declare class BrsFile {
|
|
|
47
73
|
* A collection of diagnostics related to this file
|
|
48
74
|
*/
|
|
49
75
|
diagnostics: BsDiagnostic[];
|
|
76
|
+
/**
|
|
77
|
+
* @deprecated use `.diagnostics` instead
|
|
78
|
+
*/
|
|
50
79
|
getDiagnostics(): BsDiagnostic[];
|
|
51
80
|
addDiagnostic(diagnostic: Diagnostic & {
|
|
52
|
-
file?:
|
|
81
|
+
file?: File;
|
|
53
82
|
}): void;
|
|
54
83
|
addDiagnostics(diagnostics: BsDiagnostic[]): void;
|
|
55
84
|
commentFlags: CommentFlag[];
|
|
@@ -64,8 +93,11 @@ export declare class BrsFile {
|
|
|
64
93
|
get ownScriptImports(): FileReference[];
|
|
65
94
|
/**
|
|
66
95
|
* Does this file need to be transpiled?
|
|
96
|
+
* @deprecated use the `.editor` property to push changes to the file, which will force transpilation
|
|
67
97
|
*/
|
|
68
|
-
needsTranspiled: boolean;
|
|
98
|
+
get needsTranspiled(): boolean;
|
|
99
|
+
set needsTranspiled(value: boolean);
|
|
100
|
+
_needsTranspiled: boolean;
|
|
69
101
|
/**
|
|
70
102
|
* The AST for this file
|
|
71
103
|
*/
|
|
@@ -100,19 +132,21 @@ export declare class BrsFile {
|
|
|
100
132
|
* A reference to the typedef file (if one exists)
|
|
101
133
|
*/
|
|
102
134
|
typedefFile?: BrsFile;
|
|
103
|
-
/**
|
|
104
|
-
* An unsubscribe function for the dependencyGraph subscription
|
|
105
|
-
*/
|
|
106
|
-
private unsubscribeFromDependencyGraph;
|
|
107
135
|
/**
|
|
108
136
|
* Find and set the typedef variables (if a matching typedef file exists)
|
|
109
137
|
*/
|
|
110
138
|
private resolveTypedef;
|
|
139
|
+
onDependenciesChanged(): void;
|
|
111
140
|
/**
|
|
112
141
|
* Attach the file to the dependency graph so it can monitor changes.
|
|
113
142
|
* Also notify the dependency graph of our current dependencies so other dependents can be notified.
|
|
143
|
+
* @deprecated this does nothing. This functionality is now handled by the file api and will be deleted in v1
|
|
114
144
|
*/
|
|
115
145
|
attachDependencyGraph(dependencyGraph: DependencyGraph): void;
|
|
146
|
+
/**
|
|
147
|
+
* The list of files that this file depends on
|
|
148
|
+
*/
|
|
149
|
+
get dependencies(): string[];
|
|
116
150
|
/**
|
|
117
151
|
* Calculate the AST for this file
|
|
118
152
|
* @param fileContents the raw source code to parse
|
|
@@ -199,10 +233,26 @@ export declare class BrsFile {
|
|
|
199
233
|
getClassMemberDefinitions(textToSearchFor: string, file: BrsFile): Location[];
|
|
200
234
|
getClassMethod(classStatement: ClassStatement, name: string, walkParents?: boolean): MethodStatement | undefined;
|
|
201
235
|
getReferences(position: Position): Location[];
|
|
236
|
+
/**
|
|
237
|
+
* Generate the code, map, and typedef for this file
|
|
238
|
+
*/
|
|
239
|
+
serialize(): SerializedCodeFile;
|
|
202
240
|
/**
|
|
203
241
|
* Convert the brightscript/brighterscript source code into valid brightscript
|
|
204
242
|
*/
|
|
205
243
|
transpile(): CodeWithSourceMap;
|
|
244
|
+
validationSegmenter: AstValidationSegmenter;
|
|
245
|
+
processSymbolInformation(): void;
|
|
246
|
+
getValidationSegments(changedSymbols: Map<SymbolTypeFlag, Set<string>>): AstNode[];
|
|
247
|
+
get requiredSymbols(): UnresolvedSymbol[];
|
|
248
|
+
get providedSymbols(): {
|
|
249
|
+
symbolMap: Map<SymbolTypeFlag, Map<string, BscSymbol>>;
|
|
250
|
+
changes: Map<SymbolTypeFlag, Set<string>>;
|
|
251
|
+
};
|
|
252
|
+
private getProvidedSymbols;
|
|
253
|
+
markSegmentAsValidated(node: AstNode): void;
|
|
254
|
+
getNamespaceLookupObject(): Map<string, NamespaceContainer>;
|
|
255
|
+
private buildNamespaceLookup;
|
|
206
256
|
getTypedef(): string;
|
|
207
257
|
dispose(): void;
|
|
208
258
|
}
|