brighterscript 1.0.0-alpha.23 → 1.0.0-alpha.25
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 +585 -218
- package/README.md +45 -139
- package/bsconfig.schema.json +41 -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 +152 -0
- package/dist/AstValidationSegmenter.js.map +1 -0
- package/dist/BsConfig.d.ts +39 -4
- package/dist/BusyStatusTracker.d.ts +31 -0
- package/dist/BusyStatusTracker.js +83 -0
- package/dist/BusyStatusTracker.js.map +1 -0
- package/dist/Cache.js +3 -3
- package/dist/Cache.js.map +1 -1
- package/dist/CacheVerifier.d.ts +7 -0
- package/dist/CacheVerifier.js +20 -0
- package/dist/CacheVerifier.js.map +1 -0
- package/dist/CodeActionUtil.d.ts +3 -3
- package/dist/CodeActionUtil.js.map +1 -1
- package/dist/CommentFlagProcessor.d.ts +3 -2
- package/dist/CommentFlagProcessor.js +5 -4
- package/dist/CommentFlagProcessor.js.map +1 -1
- package/dist/DependencyGraph.d.ts +3 -2
- package/dist/DependencyGraph.js +11 -10
- package/dist/DependencyGraph.js.map +1 -1
- package/dist/DiagnosticCollection.js +9 -5
- package/dist/DiagnosticCollection.js.map +1 -1
- package/dist/DiagnosticFilterer.d.ts +1 -0
- package/dist/DiagnosticFilterer.js +5 -3
- package/dist/DiagnosticFilterer.js.map +1 -1
- package/dist/DiagnosticMessages.d.ts +79 -15
- package/dist/DiagnosticMessages.js +134 -21
- package/dist/DiagnosticMessages.js.map +1 -1
- package/dist/DiagnosticSeverityAdjuster.d.ts +7 -0
- package/dist/DiagnosticSeverityAdjuster.js +41 -0
- package/dist/DiagnosticSeverityAdjuster.js.map +1 -0
- package/dist/FunctionScope.d.ts +28 -0
- package/dist/FunctionScope.js +52 -0
- package/dist/FunctionScope.js.map +1 -0
- package/dist/KeyedThrottler.d.ts +3 -3
- package/dist/KeyedThrottler.js +3 -3
- package/dist/KeyedThrottler.js.map +1 -1
- package/dist/LanguageServer.d.ts +23 -11
- package/dist/LanguageServer.js +222 -87
- package/dist/LanguageServer.js.map +1 -1
- package/dist/Logger.d.ts +3 -2
- package/dist/Logger.js +11 -3
- package/dist/Logger.js.map +1 -1
- package/dist/PluginInterface.d.ts +21 -3
- package/dist/PluginInterface.js +74 -6
- package/dist/PluginInterface.js.map +1 -1
- package/dist/Program.d.ts +162 -81
- package/dist/Program.js +903 -732
- package/dist/Program.js.map +1 -1
- package/dist/ProgramBuilder.d.ts +22 -12
- package/dist/ProgramBuilder.js +132 -104
- package/dist/ProgramBuilder.js.map +1 -1
- package/dist/Scope.d.ts +95 -134
- package/dist/Scope.js +477 -551
- package/dist/Scope.js.map +1 -1
- package/dist/Stopwatch.js +1 -1
- package/dist/Stopwatch.js.map +1 -1
- package/dist/SymbolTable.d.ts +95 -29
- package/dist/SymbolTable.js +256 -102
- package/dist/SymbolTable.js.map +1 -1
- package/dist/Throttler.d.ts +12 -0
- package/dist/Throttler.js +39 -0
- package/dist/Throttler.js.map +1 -1
- package/dist/Watcher.d.ts +0 -3
- package/dist/Watcher.js +0 -3
- package/dist/Watcher.js.map +1 -1
- package/dist/XmlScope.d.ts +4 -6
- package/dist/XmlScope.js +74 -68
- package/dist/XmlScope.js.map +1 -1
- package/dist/astUtils/CachedLookups.d.ts +48 -0
- package/dist/astUtils/CachedLookups.js +323 -0
- package/dist/astUtils/CachedLookups.js.map +1 -0
- package/dist/astUtils/{AstEditor.d.ts → Editor.d.ts} +9 -5
- package/dist/astUtils/{AstEditor.js → Editor.js} +10 -4
- package/dist/astUtils/Editor.js.map +1 -0
- package/dist/astUtils/{AstEditor.spec.js → Editor.spec.js} +68 -64
- package/dist/astUtils/Editor.spec.js.map +1 -0
- package/dist/astUtils/creators.d.ts +10 -10
- package/dist/astUtils/creators.js +26 -16
- package/dist/astUtils/creators.js.map +1 -1
- package/dist/astUtils/creators.spec.js +5 -5
- package/dist/astUtils/creators.spec.js.map +1 -1
- package/dist/astUtils/reflection.d.ts +132 -100
- package/dist/astUtils/reflection.js +225 -166
- package/dist/astUtils/reflection.js.map +1 -1
- package/dist/astUtils/reflection.spec.js +208 -126
- package/dist/astUtils/reflection.spec.js.map +1 -1
- package/dist/astUtils/stackedVisitor.spec.js +12 -12
- package/dist/astUtils/stackedVisitor.spec.js.map +1 -1
- package/dist/astUtils/visitors.d.ts +54 -35
- package/dist/astUtils/visitors.js +29 -3
- package/dist/astUtils/visitors.js.map +1 -1
- package/dist/astUtils/visitors.spec.js +178 -33
- package/dist/astUtils/visitors.spec.js.map +1 -1
- package/dist/astUtils/xml.d.ts +9 -9
- package/dist/astUtils/xml.js +9 -9
- package/dist/astUtils/xml.js.map +1 -1
- package/dist/bscPlugin/BscPlugin.d.ts +12 -2
- package/dist/bscPlugin/BscPlugin.js +41 -3
- package/dist/bscPlugin/BscPlugin.js.map +1 -1
- package/dist/bscPlugin/CallExpressionInfo.d.ts +36 -0
- package/dist/bscPlugin/CallExpressionInfo.js +131 -0
- package/dist/bscPlugin/CallExpressionInfo.js.map +1 -0
- 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/SignatureHelpUtil.d.ts +10 -0
- package/dist/bscPlugin/SignatureHelpUtil.js +135 -0
- package/dist/bscPlugin/SignatureHelpUtil.js.map +1 -0
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.d.ts +1 -1
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.js +21 -12
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.js.map +1 -1
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.spec.js +86 -12
- package/dist/bscPlugin/codeActions/CodeActionsProcessor.spec.js.map +1 -1
- package/dist/bscPlugin/completions/CompletionsProcessor.d.ts +57 -0
- package/dist/bscPlugin/completions/CompletionsProcessor.js +544 -0
- package/dist/bscPlugin/completions/CompletionsProcessor.js.map +1 -0
- package/dist/bscPlugin/completions/CompletionsProcessor.spec.js +1909 -0
- package/dist/bscPlugin/completions/CompletionsProcessor.spec.js.map +1 -0
- 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 +17 -0
- package/dist/bscPlugin/hover/HoverProcessor.js +188 -0
- package/dist/bscPlugin/hover/HoverProcessor.js.map +1 -0
- package/dist/bscPlugin/hover/HoverProcessor.spec.js +513 -0
- package/dist/bscPlugin/hover/HoverProcessor.spec.js.map +1 -0
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.d.ts +3 -1
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.js +102 -29
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.js.map +1 -1
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.spec.js +167 -6
- package/dist/bscPlugin/semanticTokens/BrsFileSemanticTokensProcessor.spec.js.map +1 -1
- package/dist/bscPlugin/serialize/BslibInjector.spec.d.ts +1 -0
- 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/BrsFileTranspileProcessor.d.ts +16 -0
- package/dist/bscPlugin/transpile/BrsFileTranspileProcessor.js +123 -0
- 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 +12 -0
- package/dist/bscPlugin/transpile/XmlFilePreTranspileProcessor.js +99 -0
- package/dist/bscPlugin/transpile/XmlFilePreTranspileProcessor.js.map +1 -0
- package/dist/bscPlugin/validation/BrsFileValidator.d.ts +22 -1
- package/dist/bscPlugin/validation/BrsFileValidator.js +316 -29
- package/dist/bscPlugin/validation/BrsFileValidator.js.map +1 -1
- package/dist/bscPlugin/validation/BrsFileValidator.spec.d.ts +1 -0
- package/dist/bscPlugin/validation/BrsFileValidator.spec.js +264 -0
- package/dist/bscPlugin/validation/BrsFileValidator.spec.js.map +1 -0
- package/dist/bscPlugin/validation/ProgramValidator.d.ts +10 -0
- package/dist/bscPlugin/validation/ProgramValidator.js +32 -0
- package/dist/bscPlugin/validation/ProgramValidator.js.map +1 -0
- package/dist/bscPlugin/validation/ScopeValidator.d.ts +56 -8
- package/dist/bscPlugin/validation/ScopeValidator.js +514 -116
- package/dist/bscPlugin/validation/ScopeValidator.js.map +1 -1
- package/dist/bscPlugin/validation/ScopeValidator.spec.d.ts +1 -0
- package/dist/bscPlugin/validation/ScopeValidator.spec.js +2454 -0
- package/dist/bscPlugin/validation/ScopeValidator.spec.js.map +1 -0
- package/dist/bscPlugin/validation/XmlFileValidator.d.ts +8 -0
- package/dist/bscPlugin/validation/XmlFileValidator.js +44 -0
- package/dist/bscPlugin/validation/XmlFileValidator.js.map +1 -0
- package/dist/cli.js +107 -8
- package/dist/cli.js.map +1 -1
- package/dist/deferred.d.ts +3 -3
- package/dist/deferred.js.map +1 -1
- package/dist/diagnosticUtils.d.ts +8 -2
- package/dist/diagnosticUtils.js +47 -17
- package/dist/diagnosticUtils.js.map +1 -1
- package/dist/examples/plugins/removePrint.js +8 -10
- 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 +529 -486
- package/dist/files/BrsFile.Class.spec.js.map +1 -1
- package/dist/files/BrsFile.d.ts +124 -112
- package/dist/files/BrsFile.js +819 -1131
- package/dist/files/BrsFile.js.map +1 -1
- package/dist/files/BrsFile.spec.js +1869 -1277
- package/dist/files/BrsFile.spec.js.map +1 -1
- package/dist/files/BscFile.d.ts +104 -0
- package/dist/files/BscFile.js +16 -0
- package/dist/files/BscFile.js.map +1 -0
- 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/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 +70 -32
- package/dist/files/XmlFile.js +106 -117
- package/dist/files/XmlFile.js.map +1 -1
- package/dist/files/XmlFile.spec.js +325 -262
- package/dist/files/XmlFile.spec.js.map +1 -1
- package/dist/files/tests/imports.spec.js +49 -41
- package/dist/files/tests/imports.spec.js.map +1 -1
- package/dist/files/tests/optionalChaning.spec.js +104 -40
- package/dist/files/tests/optionalChaning.spec.js.map +1 -1
- package/dist/globalCallables.js +16 -18
- package/dist/globalCallables.js.map +1 -1
- package/dist/index.d.ts +13 -2
- package/dist/index.js +15 -2
- package/dist/index.js.map +1 -1
- package/dist/interfaces.d.ts +440 -150
- package/dist/interfaces.js +27 -0
- package/dist/interfaces.js.map +1 -1
- package/dist/lexer/Character.spec.js +5 -5
- package/dist/lexer/Character.spec.js.map +1 -1
- package/dist/lexer/Lexer.d.ts +12 -5
- package/dist/lexer/Lexer.js +28 -13
- package/dist/lexer/Lexer.js.map +1 -1
- package/dist/lexer/Lexer.spec.js +187 -134
- package/dist/lexer/Lexer.spec.js.map +1 -1
- package/dist/lexer/Token.d.ts +9 -1
- package/dist/lexer/Token.js +9 -1
- package/dist/lexer/Token.js.map +1 -1
- package/dist/lexer/TokenKind.d.ts +9 -0
- package/dist/lexer/TokenKind.js +30 -5
- package/dist/lexer/TokenKind.js.map +1 -1
- package/dist/parser/AstNode.d.ts +162 -0
- package/dist/parser/AstNode.js +225 -0
- package/dist/parser/AstNode.js.map +1 -0
- package/dist/parser/AstNode.spec.d.ts +1 -0
- package/dist/parser/AstNode.spec.js +165 -0
- package/dist/parser/AstNode.spec.js.map +1 -0
- package/dist/parser/BrsTranspileState.d.ts +4 -7
- package/dist/parser/BrsTranspileState.js +4 -12
- package/dist/parser/BrsTranspileState.js.map +1 -1
- package/dist/parser/Expression.d.ts +126 -167
- package/dist/parser/Expression.js +524 -394
- package/dist/parser/Expression.js.map +1 -1
- package/dist/parser/Parser.Class.spec.js +152 -146
- package/dist/parser/Parser.Class.spec.js.map +1 -1
- package/dist/parser/Parser.d.ts +45 -196
- package/dist/parser/Parser.js +470 -926
- package/dist/parser/Parser.js.map +1 -1
- package/dist/parser/Parser.spec.d.ts +3 -1
- package/dist/parser/Parser.spec.js +1034 -805
- package/dist/parser/Parser.spec.js.map +1 -1
- package/dist/parser/SGParser.d.ts +9 -8
- package/dist/parser/SGParser.js +10 -8
- package/dist/parser/SGParser.js.map +1 -1
- package/dist/parser/SGParser.spec.js +27 -38
- package/dist/parser/SGParser.spec.js.map +1 -1
- package/dist/parser/SGTypes.d.ts +98 -35
- package/dist/parser/SGTypes.js +169 -99
- package/dist/parser/SGTypes.js.map +1 -1
- package/dist/parser/Statement.d.ts +208 -122
- package/dist/parser/Statement.js +599 -364
- package/dist/parser/Statement.js.map +1 -1
- package/dist/parser/Statement.spec.js +45 -21
- package/dist/parser/Statement.spec.js.map +1 -1
- package/dist/parser/TranspileState.d.ts +1 -1
- package/dist/parser/TranspileState.js +7 -12
- package/dist/parser/TranspileState.js.map +1 -1
- package/dist/parser/tests/Parser.spec.js +3 -2
- package/dist/parser/tests/Parser.spec.js.map +1 -1
- package/dist/parser/tests/controlFlow/For.spec.js +33 -23
- package/dist/parser/tests/controlFlow/For.spec.js.map +1 -1
- package/dist/parser/tests/controlFlow/ForEach.spec.js +25 -20
- package/dist/parser/tests/controlFlow/ForEach.spec.js.map +1 -1
- package/dist/parser/tests/controlFlow/If.spec.js +96 -94
- package/dist/parser/tests/controlFlow/If.spec.js.map +1 -1
- package/dist/parser/tests/controlFlow/While.spec.js +22 -16
- package/dist/parser/tests/controlFlow/While.spec.js.map +1 -1
- package/dist/parser/tests/expression/Additive.spec.js +8 -8
- package/dist/parser/tests/expression/Additive.spec.js.map +1 -1
- package/dist/parser/tests/expression/ArrayLiterals.spec.js +58 -21
- package/dist/parser/tests/expression/ArrayLiterals.spec.js.map +1 -1
- package/dist/parser/tests/expression/AssociativeArrayLiterals.spec.js +61 -20
- package/dist/parser/tests/expression/AssociativeArrayLiterals.spec.js.map +1 -1
- package/dist/parser/tests/expression/Boolean.spec.js +8 -8
- package/dist/parser/tests/expression/Boolean.spec.js.map +1 -1
- package/dist/parser/tests/expression/Call.spec.js +129 -21
- package/dist/parser/tests/expression/Call.spec.js.map +1 -1
- package/dist/parser/tests/expression/Exponential.spec.js +5 -5
- package/dist/parser/tests/expression/Exponential.spec.js.map +1 -1
- package/dist/parser/tests/expression/Function.spec.js +36 -36
- package/dist/parser/tests/expression/Function.spec.js.map +1 -1
- package/dist/parser/tests/expression/Indexing.spec.js +67 -22
- package/dist/parser/tests/expression/Indexing.spec.js.map +1 -1
- package/dist/parser/tests/expression/Multiplicative.spec.js +9 -9
- package/dist/parser/tests/expression/Multiplicative.spec.js.map +1 -1
- package/dist/parser/tests/expression/NullCoalescenceExpression.spec.js +123 -81
- package/dist/parser/tests/expression/NullCoalescenceExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/PrefixUnary.spec.js +12 -12
- package/dist/parser/tests/expression/PrefixUnary.spec.js.map +1 -1
- package/dist/parser/tests/expression/Primary.spec.js +12 -12
- package/dist/parser/tests/expression/Primary.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/Relational.spec.js +13 -13
- package/dist/parser/tests/expression/Relational.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 +221 -81
- package/dist/parser/tests/expression/TemplateStringExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/TernaryExpression.spec.js +287 -105
- package/dist/parser/tests/expression/TernaryExpression.spec.js.map +1 -1
- package/dist/parser/tests/expression/TypeExpression.spec.d.ts +1 -0
- package/dist/parser/tests/expression/TypeExpression.spec.js +127 -0
- package/dist/parser/tests/expression/TypeExpression.spec.js.map +1 -0
- 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/AssignmentOperators.spec.js +15 -15
- package/dist/parser/tests/statement/AssignmentOperators.spec.js.map +1 -1
- package/dist/parser/tests/statement/ConstStatement.spec.d.ts +1 -0
- package/dist/parser/tests/statement/ConstStatement.spec.js +262 -0
- package/dist/parser/tests/statement/ConstStatement.spec.js.map +1 -0
- package/dist/parser/tests/statement/Continue.spec.d.ts +1 -0
- package/dist/parser/tests/statement/Continue.spec.js +119 -0
- package/dist/parser/tests/statement/Continue.spec.js.map +1 -0
- package/dist/parser/tests/statement/Declaration.spec.js +19 -19
- package/dist/parser/tests/statement/Declaration.spec.js.map +1 -1
- package/dist/parser/tests/statement/Dim.spec.js +22 -22
- package/dist/parser/tests/statement/Dim.spec.js.map +1 -1
- package/dist/parser/tests/statement/Enum.spec.js +111 -300
- package/dist/parser/tests/statement/Enum.spec.js.map +1 -1
- package/dist/parser/tests/statement/For.spec.js +9 -10
- package/dist/parser/tests/statement/For.spec.js.map +1 -1
- package/dist/parser/tests/statement/ForEach.spec.js +8 -9
- package/dist/parser/tests/statement/ForEach.spec.js.map +1 -1
- package/dist/parser/tests/statement/Function.spec.js +44 -35
- package/dist/parser/tests/statement/Function.spec.js.map +1 -1
- package/dist/parser/tests/statement/Goto.spec.js +5 -5
- package/dist/parser/tests/statement/Goto.spec.js.map +1 -1
- package/dist/parser/tests/statement/Increment.spec.js +20 -20
- package/dist/parser/tests/statement/Increment.spec.js.map +1 -1
- package/dist/parser/tests/statement/InterfaceStatement.spec.js +30 -196
- package/dist/parser/tests/statement/InterfaceStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/LibraryStatement.spec.js +11 -11
- package/dist/parser/tests/statement/LibraryStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/Misc.spec.js +16 -78
- package/dist/parser/tests/statement/Misc.spec.js.map +1 -1
- package/dist/parser/tests/statement/PrintStatement.spec.js +107 -90
- package/dist/parser/tests/statement/PrintStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/ReturnStatement.spec.js +14 -12
- package/dist/parser/tests/statement/ReturnStatement.spec.js.map +1 -1
- package/dist/parser/tests/statement/Set.spec.js +48 -35
- package/dist/parser/tests/statement/Set.spec.js.map +1 -1
- package/dist/parser/tests/statement/Stop.spec.js +6 -6
- package/dist/parser/tests/statement/Stop.spec.js.map +1 -1
- package/dist/parser/tests/statement/Throw.spec.js +6 -6
- package/dist/parser/tests/statement/Throw.spec.js.map +1 -1
- package/dist/parser/tests/statement/TryCatch.spec.js +18 -16
- package/dist/parser/tests/statement/TryCatch.spec.js.map +1 -1
- package/dist/preprocessor/Manifest.d.ts +1 -1
- package/dist/preprocessor/Manifest.js +3 -3
- package/dist/preprocessor/Manifest.js.map +1 -1
- package/dist/preprocessor/Manifest.spec.js +8 -8
- package/dist/preprocessor/Manifest.spec.js.map +1 -1
- package/dist/preprocessor/Preprocessor.d.ts +5 -6
- package/dist/preprocessor/Preprocessor.js +15 -11
- package/dist/preprocessor/Preprocessor.js.map +1 -1
- package/dist/preprocessor/Preprocessor.spec.js +25 -25
- package/dist/preprocessor/Preprocessor.spec.js.map +1 -1
- package/dist/preprocessor/PreprocessorParser.d.ts +1 -1
- package/dist/preprocessor/PreprocessorParser.js +7 -1
- package/dist/preprocessor/PreprocessorParser.js.map +1 -1
- package/dist/preprocessor/PreprocessorParser.spec.js +13 -13
- package/dist/preprocessor/PreprocessorParser.spec.js.map +1 -1
- package/dist/roku-types/data.json +6544 -10519
- package/dist/roku-types/index.d.ts +662 -1934
- package/dist/types/ArrayType.d.ts +10 -9
- package/dist/types/ArrayType.js +65 -60
- package/dist/types/ArrayType.js.map +1 -1
- package/dist/types/ArrayType.spec.js +36 -68
- package/dist/types/ArrayType.spec.js.map +1 -1
- package/dist/types/AssociativeArrayType.d.ts +11 -0
- package/dist/types/AssociativeArrayType.js +52 -0
- package/dist/types/AssociativeArrayType.js.map +1 -0
- package/dist/types/BaseFunctionType.d.ts +9 -0
- package/dist/types/BaseFunctionType.js +25 -0
- package/dist/types/BaseFunctionType.js.map +1 -0
- package/dist/types/BooleanType.d.ts +8 -5
- package/dist/types/BooleanType.js +14 -7
- package/dist/types/BooleanType.js.map +1 -1
- package/dist/types/BooleanType.spec.js +10 -6
- package/dist/types/BooleanType.spec.js.map +1 -1
- package/dist/types/BscType.d.ts +32 -21
- package/dist/types/BscType.js +118 -21
- package/dist/types/BscType.js.map +1 -1
- package/dist/types/BscTypeKind.d.ts +25 -0
- package/dist/types/BscTypeKind.js +30 -0
- package/dist/types/BscTypeKind.js.map +1 -0
- package/dist/types/BuiltInInterfaceAdder.d.ts +23 -0
- package/dist/types/BuiltInInterfaceAdder.js +164 -0
- package/dist/types/BuiltInInterfaceAdder.js.map +1 -0
- package/dist/types/BuiltInInterfaceAdder.spec.d.ts +1 -0
- package/dist/types/BuiltInInterfaceAdder.spec.js +116 -0
- package/dist/types/BuiltInInterfaceAdder.spec.js.map +1 -0
- package/dist/types/ClassType.d.ts +17 -0
- package/dist/types/ClassType.js +58 -0
- package/dist/types/ClassType.js.map +1 -0
- package/dist/types/ClassType.spec.d.ts +1 -0
- package/dist/types/ClassType.spec.js +77 -0
- package/dist/types/ClassType.spec.js.map +1 -0
- package/dist/types/ComponentType.d.ts +26 -0
- package/dist/types/ComponentType.js +83 -0
- package/dist/types/ComponentType.js.map +1 -0
- package/dist/types/DoubleType.d.ts +8 -5
- package/dist/types/DoubleType.js +18 -16
- package/dist/types/DoubleType.js.map +1 -1
- package/dist/types/DoubleType.spec.js +12 -6
- package/dist/types/DoubleType.spec.js.map +1 -1
- package/dist/types/DynamicType.d.ts +10 -5
- package/dist/types/DynamicType.js +16 -4
- package/dist/types/DynamicType.js.map +1 -1
- package/dist/types/DynamicType.spec.js +16 -5
- package/dist/types/DynamicType.spec.js.map +1 -1
- package/dist/types/EnumType.d.ts +30 -12
- package/dist/types/EnumType.js +43 -17
- package/dist/types/EnumType.js.map +1 -1
- package/dist/types/EnumType.spec.d.ts +1 -0
- package/dist/types/EnumType.spec.js +33 -0
- package/dist/types/EnumType.spec.js.map +1 -0
- package/dist/types/FloatType.d.ts +8 -5
- package/dist/types/FloatType.js +18 -16
- package/dist/types/FloatType.js.map +1 -1
- package/dist/types/FloatType.spec.js +4 -6
- package/dist/types/FloatType.spec.js.map +1 -1
- package/dist/types/FunctionType.d.ts +13 -8
- package/dist/types/FunctionType.js +30 -14
- package/dist/types/FunctionType.js.map +1 -1
- package/dist/types/InheritableType.d.ts +28 -0
- package/dist/types/InheritableType.js +152 -0
- package/dist/types/InheritableType.js.map +1 -0
- package/dist/types/IntegerType.d.ts +8 -5
- package/dist/types/IntegerType.js +18 -16
- package/dist/types/IntegerType.js.map +1 -1
- package/dist/types/IntegerType.spec.js +8 -6
- package/dist/types/IntegerType.spec.js.map +1 -1
- package/dist/types/InterfaceType.d.ts +12 -13
- package/dist/types/InterfaceType.js +20 -48
- package/dist/types/InterfaceType.js.map +1 -1
- package/dist/types/InterfaceType.spec.js +90 -56
- package/dist/types/InterfaceType.spec.js.map +1 -1
- package/dist/types/InvalidType.d.ts +7 -5
- package/dist/types/InvalidType.js +13 -7
- package/dist/types/InvalidType.js.map +1 -1
- package/dist/types/InvalidType.spec.js +8 -6
- package/dist/types/InvalidType.spec.js.map +1 -1
- package/dist/types/LongIntegerType.d.ts +8 -5
- package/dist/types/LongIntegerType.js +17 -15
- package/dist/types/LongIntegerType.js.map +1 -1
- package/dist/types/LongIntegerType.spec.js +10 -6
- package/dist/types/LongIntegerType.spec.js.map +1 -1
- package/dist/types/NamespaceType.d.ts +12 -0
- package/dist/types/NamespaceType.js +28 -0
- package/dist/types/NamespaceType.js.map +1 -0
- package/dist/types/ObjectType.d.ts +9 -8
- package/dist/types/ObjectType.js +21 -11
- package/dist/types/ObjectType.js.map +1 -1
- package/dist/types/ObjectType.spec.js +3 -3
- package/dist/types/ObjectType.spec.js.map +1 -1
- package/dist/types/ReferenceType.d.ts +63 -0
- package/dist/types/ReferenceType.js +423 -0
- package/dist/types/ReferenceType.js.map +1 -0
- package/dist/types/ReferenceType.spec.d.ts +1 -0
- package/dist/types/ReferenceType.spec.js +137 -0
- package/dist/types/ReferenceType.spec.js.map +1 -0
- package/dist/types/StringType.d.ts +11 -5
- package/dist/types/StringType.js +18 -7
- package/dist/types/StringType.js.map +1 -1
- package/dist/types/StringType.spec.js +3 -5
- package/dist/types/StringType.spec.js.map +1 -1
- package/dist/types/TypedFunctionType.d.ts +22 -17
- package/dist/types/TypedFunctionType.js +78 -60
- package/dist/types/TypedFunctionType.js.map +1 -1
- package/dist/types/TypedFunctionType.spec.js +105 -20
- package/dist/types/TypedFunctionType.spec.js.map +1 -1
- package/dist/types/UninitializedType.d.ts +8 -6
- package/dist/types/UninitializedType.js +13 -7
- package/dist/types/UninitializedType.js.map +1 -1
- package/dist/types/UnionType.d.ts +20 -0
- package/dist/types/UnionType.js +123 -0
- package/dist/types/UnionType.js.map +1 -0
- package/dist/types/UnionType.spec.d.ts +1 -0
- package/dist/types/UnionType.spec.js +130 -0
- package/dist/types/UnionType.spec.js.map +1 -0
- package/dist/types/VoidType.d.ts +8 -5
- package/dist/types/VoidType.js +14 -7
- package/dist/types/VoidType.js.map +1 -1
- package/dist/types/VoidType.spec.js +3 -3
- package/dist/types/VoidType.spec.js.map +1 -1
- package/dist/types/helper.spec.d.ts +1 -0
- package/dist/types/helper.spec.js +145 -0
- package/dist/types/helper.spec.js.map +1 -0
- package/dist/types/helpers.d.ts +19 -37
- package/dist/types/helpers.js +159 -99
- package/dist/types/helpers.js.map +1 -1
- package/dist/types/index.d.ts +22 -0
- package/dist/types/index.js +39 -0
- package/dist/types/index.js.map +1 -0
- package/dist/util.d.ts +167 -131
- package/dist/util.js +890 -350
- package/dist/util.js.map +1 -1
- package/dist/validators/ClassValidator.d.ts +7 -25
- package/dist/validators/ClassValidator.js +103 -194
- package/dist/validators/ClassValidator.js.map +1 -1
- package/package.json +165 -149
- package/dist/astUtils/AstEditor.js.map +0 -1
- package/dist/astUtils/AstEditor.spec.js.map +0 -1
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.d.ts +0 -8
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.js +0 -40
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.js.map +0 -1
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.spec.js +0 -32
- package/dist/bscPlugin/transpile/BrsFilePreTranspileProcessor.spec.js.map +0 -1
- package/dist/parser/SGTypes.spec.js +0 -351
- package/dist/parser/SGTypes.spec.js.map +0 -1
- package/dist/types/CustomType.d.ts +0 -12
- package/dist/types/CustomType.js +0 -44
- package/dist/types/CustomType.js.map +0 -1
- package/dist/types/LazyType.d.ts +0 -16
- package/dist/types/LazyType.js +0 -44
- package/dist/types/LazyType.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 → completions/CompletionsProcessor.spec.d.ts} +0 -0
- /package/dist/{parser/SGTypes.spec.d.ts → bscPlugin/hover/HoverProcessor.spec.d.ts} +0 -0
package/dist/interfaces.d.ts
CHANGED
|
@@ -1,20 +1,25 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
import type { Range, Diagnostic, CodeAction, SemanticTokenTypes, SemanticTokenModifiers, Position, CompletionItem } from 'vscode-languageserver';
|
|
2
3
|
import type { Scope } from './Scope';
|
|
3
4
|
import type { BrsFile } from './files/BrsFile';
|
|
4
5
|
import type { XmlFile } from './files/XmlFile';
|
|
6
|
+
import type { FunctionScope } from './FunctionScope';
|
|
5
7
|
import type { TypedFunctionType } from './types/TypedFunctionType';
|
|
6
8
|
import type { ParseMode } from './parser/Parser';
|
|
7
9
|
import type { Program } from './Program';
|
|
8
10
|
import type { ProgramBuilder } from './ProgramBuilder';
|
|
9
|
-
import type {
|
|
10
|
-
import type { Expression,
|
|
11
|
+
import type { ClassStatement, ConstStatement, EnumStatement, FunctionStatement, NamespaceStatement } from './parser/Statement';
|
|
12
|
+
import type { AstNode, Expression, Statement } from './parser/AstNode';
|
|
11
13
|
import type { TranspileState } from './parser/TranspileState';
|
|
12
|
-
import type {
|
|
13
|
-
import type { BscType
|
|
14
|
-
import type {
|
|
15
|
-
import type {
|
|
16
|
-
import type {
|
|
17
|
-
import type {
|
|
14
|
+
import type { SourceNode } from 'source-map';
|
|
15
|
+
import type { BscType } from './types/BscType';
|
|
16
|
+
import type { Editor } from './astUtils/Editor';
|
|
17
|
+
import type { Identifier, Token } from './lexer/Token';
|
|
18
|
+
import type { BscFile } from './files/BscFile';
|
|
19
|
+
import type { FileFactory } from './files/Factory';
|
|
20
|
+
import type { LazyFileData } from './files/LazyFileData';
|
|
21
|
+
import type { SymbolTable, SymbolTypeFlag } from './SymbolTable';
|
|
22
|
+
import type { CallExpression } from './parser/Expression';
|
|
18
23
|
export interface BsDiagnostic extends Diagnostic {
|
|
19
24
|
file: BscFile;
|
|
20
25
|
/**
|
|
@@ -22,7 +27,16 @@ export interface BsDiagnostic extends Diagnostic {
|
|
|
22
27
|
*/
|
|
23
28
|
data?: any;
|
|
24
29
|
}
|
|
25
|
-
export declare
|
|
30
|
+
export declare enum DiagnosticOrigin {
|
|
31
|
+
Program = "Program",
|
|
32
|
+
Scope = "Scope",
|
|
33
|
+
File = "File",
|
|
34
|
+
ASTSegment = "AstSegment"
|
|
35
|
+
}
|
|
36
|
+
export interface BsDiagnosticWithOrigin extends BsDiagnostic {
|
|
37
|
+
origin: DiagnosticOrigin;
|
|
38
|
+
astSegment?: AstNode;
|
|
39
|
+
}
|
|
26
40
|
export interface Callable {
|
|
27
41
|
file: BscFile;
|
|
28
42
|
name: string;
|
|
@@ -64,12 +78,12 @@ export interface FunctionCall {
|
|
|
64
78
|
* The full range of this function call (from the start of the function name to its closing paren)
|
|
65
79
|
*/
|
|
66
80
|
range: Range;
|
|
67
|
-
|
|
81
|
+
expression: CallExpression;
|
|
82
|
+
functionScope: FunctionScope;
|
|
68
83
|
file: BscFile;
|
|
69
|
-
name:
|
|
84
|
+
name: string;
|
|
70
85
|
args: CallableArg[];
|
|
71
86
|
nameRange: Range;
|
|
72
|
-
isDottedInvocation: boolean;
|
|
73
87
|
}
|
|
74
88
|
/**
|
|
75
89
|
* An argument for an expression call.
|
|
@@ -102,12 +116,12 @@ export interface FileObj {
|
|
|
102
116
|
*/
|
|
103
117
|
export interface FileReference {
|
|
104
118
|
/**
|
|
105
|
-
* The
|
|
119
|
+
* The destPath for the referenced file.
|
|
106
120
|
*/
|
|
107
|
-
|
|
121
|
+
destPath: string;
|
|
108
122
|
text: string;
|
|
109
123
|
/**
|
|
110
|
-
* The file that is doing the import. Note this is NOT the file the
|
|
124
|
+
* The file that is doing the import. Note this is NOT the file the destPath points to.
|
|
111
125
|
*/
|
|
112
126
|
sourceFile: XmlFile | BrsFile;
|
|
113
127
|
/**
|
|
@@ -120,7 +134,7 @@ export interface FileReference {
|
|
|
120
134
|
}
|
|
121
135
|
export interface VariableDeclaration {
|
|
122
136
|
name: string;
|
|
123
|
-
|
|
137
|
+
getType: () => BscType;
|
|
124
138
|
/**
|
|
125
139
|
* The range for the variable name
|
|
126
140
|
*/
|
|
@@ -165,26 +179,109 @@ export interface CommentFlag {
|
|
|
165
179
|
export declare type CompilerPluginFactory = () => CompilerPlugin;
|
|
166
180
|
export interface CompilerPlugin {
|
|
167
181
|
name: string;
|
|
182
|
+
/**
|
|
183
|
+
* Called before a new program is created
|
|
184
|
+
*/
|
|
168
185
|
beforeProgramCreate?: PluginHandler<BeforeProgramCreateEvent>;
|
|
186
|
+
/**
|
|
187
|
+
* Called after a new program is created
|
|
188
|
+
*/
|
|
169
189
|
afterProgramCreate?: PluginHandler<AfterProgramCreateEvent>;
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
190
|
+
/**
|
|
191
|
+
* Called before the program gets prepared for building
|
|
192
|
+
*/
|
|
193
|
+
beforePrepareProgram?: PluginHandler<BeforePrepareProgramEvent>;
|
|
194
|
+
/**
|
|
195
|
+
* Called when the program gets prepared for building
|
|
196
|
+
*/
|
|
197
|
+
prepareProgram?: PluginHandler<PrepareProgramEvent>;
|
|
198
|
+
/**
|
|
199
|
+
* Called after the program gets prepared for building
|
|
200
|
+
*/
|
|
201
|
+
afterPrepareProgram?: PluginHandler<AfterPrepareProgramEvent>;
|
|
202
|
+
/**
|
|
203
|
+
* Called before the entire program is validated
|
|
204
|
+
*/
|
|
174
205
|
beforeProgramValidate?: PluginHandler<BeforeProgramValidateEvent>;
|
|
206
|
+
/**
|
|
207
|
+
* Called before the entire program is validated
|
|
208
|
+
*/
|
|
209
|
+
onProgramValidate?: PluginHandler<OnProgramValidateEvent>;
|
|
210
|
+
/**
|
|
211
|
+
* Called after the program has been validated
|
|
212
|
+
*/
|
|
175
213
|
afterProgramValidate?: PluginHandler<AfterProgramValidateEvent>;
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
214
|
+
/**
|
|
215
|
+
* Called right before the program is disposed/destroyed
|
|
216
|
+
*/
|
|
217
|
+
beforeProgramDispose?: PluginHandler<BeforeProgramDisposeEvent>;
|
|
218
|
+
/**
|
|
219
|
+
* Emitted before the program starts collecting completions
|
|
220
|
+
*/
|
|
221
|
+
beforeProvideCompletions?: PluginHandler<BeforeProvideCompletionsEvent>;
|
|
222
|
+
/**
|
|
223
|
+
* Use this event to contribute completions
|
|
224
|
+
*/
|
|
225
|
+
provideCompletions?: PluginHandler<ProvideCompletionsEvent>;
|
|
226
|
+
/**
|
|
227
|
+
* Emitted after the program has finished collecting completions, but before they are sent to the client
|
|
228
|
+
*/
|
|
229
|
+
afterProvideCompletions?: PluginHandler<AfterProvideCompletionsEvent>;
|
|
230
|
+
/**
|
|
231
|
+
* Called before the `provideHover` hook. Use this if you need to prepare any of the in-memory objects before the `provideHover` gets called
|
|
232
|
+
*/
|
|
233
|
+
beforeProvideHover?: PluginHandler<BeforeProvideHoverEvent>;
|
|
234
|
+
/**
|
|
235
|
+
* Called when bsc looks for hover information. Use this if your plugin wants to contribute hover information.
|
|
236
|
+
*/
|
|
237
|
+
provideHover?: PluginHandler<ProvideHoverEvent>;
|
|
238
|
+
/**
|
|
239
|
+
* Called after the `provideHover` hook. Use this if you want to intercept or sanitize the hover data (even from other plugins) before it gets sent to the client.
|
|
240
|
+
*/
|
|
241
|
+
afterProvideHover?: PluginHandler<AfterProvideHoverEvent>;
|
|
242
|
+
/**
|
|
243
|
+
* Called after a scope was created
|
|
244
|
+
*/
|
|
180
245
|
afterScopeCreate?: PluginHandler<AfterScopeCreateEvent>;
|
|
181
246
|
beforeScopeDispose?: PluginHandler<BeforeScopeDisposeEvent>;
|
|
247
|
+
onScopeDispose?: PluginHandler<OnScopeDisposeEvent>;
|
|
182
248
|
afterScopeDispose?: PluginHandler<AfterScopeDisposeEvent>;
|
|
183
249
|
beforeScopeValidate?: PluginHandler<BeforeScopeValidateEvent>;
|
|
184
250
|
onScopeValidate?: PluginHandler<OnScopeValidateEvent>;
|
|
185
|
-
afterScopeValidate?: PluginHandler<
|
|
186
|
-
|
|
187
|
-
|
|
251
|
+
afterScopeValidate?: PluginHandler<BeforeScopeValidateEvent>;
|
|
252
|
+
onGetCodeActions?: PluginHandler<OnGetCodeActionsEvent>;
|
|
253
|
+
onGetSemanticTokens?: PluginHandler<OnGetSemanticTokensEvent>;
|
|
254
|
+
/**
|
|
255
|
+
* Called before plugins are asked to provide files to the program. (excludes virtual files produced by `provideFile` events).
|
|
256
|
+
* Call the `setFileData()` method to override the file contents.
|
|
257
|
+
*/
|
|
258
|
+
beforeProvideFile?: PluginHandler<BeforeProvideFileEvent>;
|
|
259
|
+
/**
|
|
260
|
+
* Give plugins the opportunity to handle processing a file. (excludes virtual files produced by `provideFile` events)
|
|
261
|
+
*/
|
|
262
|
+
provideFile?: PluginHandler<ProvideFileEvent>;
|
|
263
|
+
/**
|
|
264
|
+
* Called after a file was added to the program. (excludes virtual files produced by `provideFile` events)
|
|
265
|
+
*/
|
|
266
|
+
afterProvideFile?: PluginHandler<AfterProvideFileEvent>;
|
|
267
|
+
/**
|
|
268
|
+
* Called before a file is added to the program.
|
|
269
|
+
* Includes physical files as well as any virtual files produced by `provideFile` events
|
|
270
|
+
*/
|
|
271
|
+
beforeFileAdd?: PluginHandler<BeforeFileAddEvent>;
|
|
272
|
+
/**
|
|
273
|
+
* Called after a file has been added to the program.
|
|
274
|
+
* Includes physical files as well as any virtual files produced by `provideFile` events
|
|
275
|
+
*/
|
|
276
|
+
afterFileAdd?: PluginHandler<AfterFileAddEvent>;
|
|
277
|
+
/**
|
|
278
|
+
* Called before a file is removed from the program. This includes physical and virtual files
|
|
279
|
+
*/
|
|
280
|
+
beforeFileRemove?: PluginHandler<BeforeFileRemoveEvent>;
|
|
281
|
+
/**
|
|
282
|
+
* Called after a file has been removed from the program. This includes physical and virtual files
|
|
283
|
+
*/
|
|
284
|
+
afterFileRemove?: PluginHandler<AfterFileRemoveEvent>;
|
|
188
285
|
/**
|
|
189
286
|
* Called before each file is validated
|
|
190
287
|
*/
|
|
@@ -197,34 +294,83 @@ export interface CompilerPlugin {
|
|
|
197
294
|
* Called after each file is validated
|
|
198
295
|
*/
|
|
199
296
|
afterFileValidate?: PluginHandler<AfterFileValidateEvent>;
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
297
|
+
/**
|
|
298
|
+
* Called right before the program builds (i.e. generates the code and puts it in the stagingDir
|
|
299
|
+
*/
|
|
300
|
+
beforeBuildProgram?: PluginHandler<BeforeBuildProgramEvent>;
|
|
301
|
+
/**
|
|
302
|
+
* Called right after the program builds (i.e. generates the code and puts it in the stagingDir
|
|
303
|
+
*/
|
|
304
|
+
afterBuildProgram?: PluginHandler<AfterBuildProgramEvent>;
|
|
305
|
+
/**
|
|
306
|
+
* Before preparing the file for building
|
|
307
|
+
*/
|
|
308
|
+
beforePrepareFile?: PluginHandler<BeforePrepareFileEvent>;
|
|
309
|
+
/**
|
|
310
|
+
* Prepare the file for building
|
|
311
|
+
*/
|
|
312
|
+
prepareFile?: PluginHandler<PrepareFileEvent>;
|
|
313
|
+
/**
|
|
314
|
+
* After preparing the file for building
|
|
315
|
+
*/
|
|
316
|
+
afterPrepareFile?: PluginHandler<AfterPrepareFileEvent>;
|
|
317
|
+
/**
|
|
318
|
+
* Before the program turns all file objects into their final buffers
|
|
319
|
+
*/
|
|
320
|
+
beforeSerializeProgram?: PluginHandler<BeforeSerializeProgramEvent>;
|
|
321
|
+
/**
|
|
322
|
+
* Emitted right at the start of the program turning all file objects into their final buffers
|
|
323
|
+
*/
|
|
324
|
+
onSerializeProgram?: PluginHandler<OnSerializeProgramEvent>;
|
|
325
|
+
/**
|
|
326
|
+
* After the program turns all file objects into their final buffers
|
|
327
|
+
*/
|
|
328
|
+
afterSerializeProgram?: PluginHandler<AfterSerializeProgramEvent>;
|
|
329
|
+
/**
|
|
330
|
+
* Before turning the file into its final contents
|
|
331
|
+
*/
|
|
332
|
+
beforeSerializeFile?: PluginHandler<BeforeSerializeFileEvent>;
|
|
333
|
+
/**
|
|
334
|
+
* Turn the file into its final contents (i.e. transpile a bs file, compress a jpeg, etc)
|
|
335
|
+
*/
|
|
336
|
+
serializeFile?: PluginHandler<SerializeFileEvent>;
|
|
337
|
+
/**
|
|
338
|
+
* After turning the file into its final contents
|
|
339
|
+
*/
|
|
340
|
+
afterSerializeFile?: PluginHandler<AfterSerializeFileEvent>;
|
|
341
|
+
/**
|
|
342
|
+
* Called before any files are written
|
|
343
|
+
*/
|
|
344
|
+
beforeWriteProgram?: PluginHandler<BeforeWriteProgramEvent>;
|
|
345
|
+
/**
|
|
346
|
+
* Called after all files are written
|
|
347
|
+
*/
|
|
348
|
+
afterWriteProgram?: PluginHandler<AfterWriteProgramEvent>;
|
|
349
|
+
/**
|
|
350
|
+
* Before a file is written to disk. These are raw files that contain the final output. One `File` may produce several of these
|
|
351
|
+
*/
|
|
352
|
+
beforeWriteFile?: PluginHandler<BeforeWriteFileEvent>;
|
|
353
|
+
/**
|
|
354
|
+
* Called when a file should be persisted (usually writing to storage). These are raw files that contain the final output. One `File` may produce several of these.
|
|
355
|
+
* When a plugin has handled a file, it should be pushed to the `handledFiles` set so future plugins don't write the file multiple times
|
|
356
|
+
*/
|
|
357
|
+
writeFile?: PluginHandler<WriteFileEvent>;
|
|
358
|
+
/**
|
|
359
|
+
* Before a file is written to disk. These are raw files that contain the final output. One `File` may produce several of these
|
|
360
|
+
*/
|
|
361
|
+
afterWriteFile?: PluginHandler<AfterWriteFileEvent>;
|
|
218
362
|
}
|
|
219
|
-
export
|
|
220
|
-
|
|
363
|
+
export declare type PluginHandler<T, R = void> = (event: T) => R;
|
|
364
|
+
export interface OnGetCodeActionsEvent<TFile extends BscFile = BscFile> {
|
|
221
365
|
program: Program;
|
|
222
|
-
|
|
366
|
+
file: TFile;
|
|
367
|
+
range: Range;
|
|
368
|
+
scopes: Scope[];
|
|
369
|
+
diagnostics: BsDiagnostic[];
|
|
370
|
+
codeActions: CodeAction[];
|
|
223
371
|
}
|
|
224
|
-
export interface
|
|
372
|
+
export interface BeforeProgramCreateEvent {
|
|
225
373
|
builder: ProgramBuilder;
|
|
226
|
-
program: Program;
|
|
227
|
-
files: FileObj[];
|
|
228
374
|
}
|
|
229
375
|
export interface AfterProgramCreateEvent {
|
|
230
376
|
builder: ProgramBuilder;
|
|
@@ -233,27 +379,47 @@ export interface AfterProgramCreateEvent {
|
|
|
233
379
|
export interface BeforeProgramValidateEvent {
|
|
234
380
|
program: Program;
|
|
235
381
|
}
|
|
236
|
-
export
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
export interface BeforeProgramTranspileEvent {
|
|
382
|
+
export declare type OnProgramValidateEvent = BeforeProgramValidateEvent;
|
|
383
|
+
export declare type AfterProgramValidateEvent = BeforeProgramValidateEvent;
|
|
384
|
+
export interface ProvideCompletionsEvent<TFile extends BscFile = BscFile> {
|
|
240
385
|
program: Program;
|
|
241
|
-
|
|
242
|
-
|
|
386
|
+
file: TFile;
|
|
387
|
+
scopes: Scope[];
|
|
388
|
+
position: Position;
|
|
389
|
+
completions: CompletionItem[];
|
|
243
390
|
}
|
|
244
|
-
export
|
|
391
|
+
export declare type BeforeProvideCompletionsEvent<TFile extends BscFile = BscFile> = ProvideCompletionsEvent<TFile>;
|
|
392
|
+
export declare type AfterProvideCompletionsEvent<TFile extends BscFile = BscFile> = ProvideCompletionsEvent<TFile>;
|
|
393
|
+
export interface BeforeBuildProgramEvent {
|
|
245
394
|
program: Program;
|
|
246
|
-
|
|
247
|
-
editor:
|
|
395
|
+
files: BscFile[];
|
|
396
|
+
editor: Editor;
|
|
248
397
|
}
|
|
249
|
-
export
|
|
398
|
+
export declare type AfterBuildProgramEvent = BeforeBuildProgramEvent;
|
|
399
|
+
export interface ProvideHoverEvent {
|
|
250
400
|
program: Program;
|
|
251
401
|
file: BscFile;
|
|
252
|
-
|
|
402
|
+
position: Position;
|
|
253
403
|
scopes: Scope[];
|
|
254
|
-
|
|
255
|
-
|
|
404
|
+
hovers: Hover[];
|
|
405
|
+
}
|
|
406
|
+
export interface Hover {
|
|
407
|
+
/**
|
|
408
|
+
* The contents of the hover, written in markdown. If you want to display code in the hover, use code blocks, like this:
|
|
409
|
+
* ```text
|
|
410
|
+
* ```brighterscript
|
|
411
|
+
* some = "code" + "here"
|
|
412
|
+
* ```
|
|
413
|
+
* ```
|
|
414
|
+
*/
|
|
415
|
+
contents: string | string[];
|
|
416
|
+
/**
|
|
417
|
+
* An optional range
|
|
418
|
+
*/
|
|
419
|
+
range?: Range;
|
|
256
420
|
}
|
|
421
|
+
export declare type BeforeProvideHoverEvent = ProvideHoverEvent;
|
|
422
|
+
export declare type AfterProvideHoverEvent = ProvideHoverEvent;
|
|
257
423
|
export interface AfterScopeCreateEvent {
|
|
258
424
|
program: Program;
|
|
259
425
|
scope: Scope;
|
|
@@ -262,30 +428,25 @@ export interface BeforeScopeDisposeEvent {
|
|
|
262
428
|
program: Program;
|
|
263
429
|
scope: Scope;
|
|
264
430
|
}
|
|
265
|
-
export interface
|
|
431
|
+
export interface OnScopeDisposeEvent {
|
|
266
432
|
program: Program;
|
|
267
433
|
scope: Scope;
|
|
268
434
|
}
|
|
269
|
-
export interface
|
|
435
|
+
export interface AfterScopeDisposeEvent {
|
|
270
436
|
program: Program;
|
|
271
437
|
scope: Scope;
|
|
272
438
|
}
|
|
273
|
-
export interface
|
|
439
|
+
export interface BeforeScopeValidateEvent {
|
|
274
440
|
program: Program;
|
|
275
441
|
scope: Scope;
|
|
276
442
|
}
|
|
277
|
-
export
|
|
443
|
+
export declare type AfterScopeValidateEvent = BeforeScopeValidateEvent;
|
|
444
|
+
export interface BeforeFileParseEvent {
|
|
278
445
|
program: Program;
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
range: Range;
|
|
282
|
-
/**
|
|
283
|
-
* A filtered list of diagnostics whose lines touch the lines of the given range
|
|
284
|
-
*/
|
|
285
|
-
diagnostics: BsDiagnostic[];
|
|
286
|
-
codeActions: CodeAction[];
|
|
446
|
+
srcPath: string;
|
|
447
|
+
source: string;
|
|
287
448
|
}
|
|
288
|
-
export interface
|
|
449
|
+
export interface OnFileParseEvent {
|
|
289
450
|
program: Program;
|
|
290
451
|
srcPath: string;
|
|
291
452
|
source: string;
|
|
@@ -312,28 +473,30 @@ export interface OnGetSemanticTokensEvent<T extends BscFile = BscFile> {
|
|
|
312
473
|
*/
|
|
313
474
|
semanticTokens: SemanticToken[];
|
|
314
475
|
}
|
|
315
|
-
export
|
|
476
|
+
export declare type BeforeFileValidateEvent = OnFileValidateEvent;
|
|
477
|
+
export interface OnFileValidateEvent<T extends BscFile = BscFile> {
|
|
316
478
|
program: Program;
|
|
317
479
|
file: T;
|
|
318
480
|
}
|
|
481
|
+
export declare type AfterFileValidateEvent = OnFileValidateEvent;
|
|
319
482
|
export interface OnFileValidateEvent<T extends BscFile = BscFile> {
|
|
320
483
|
program: Program;
|
|
321
484
|
file: T;
|
|
322
485
|
}
|
|
323
|
-
export interface
|
|
324
|
-
|
|
325
|
-
|
|
486
|
+
export interface TranspileEntry {
|
|
487
|
+
file: BscFile;
|
|
488
|
+
outputPath: string;
|
|
326
489
|
}
|
|
327
|
-
export interface
|
|
490
|
+
export interface ScopeValidationOptions {
|
|
491
|
+
changedFiles?: BscFile[];
|
|
492
|
+
changedSymbols?: Map<SymbolTypeFlag, Set<string>>;
|
|
493
|
+
force?: boolean;
|
|
494
|
+
}
|
|
495
|
+
export interface OnScopeValidateEvent {
|
|
328
496
|
program: Program;
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
* An editor that can be used to transform properties or arrays. Once the `afterFileTranspile` event has fired, these changes will be reverted,
|
|
333
|
-
* restoring the objects to their prior state. This is useful for changing code right before a file gets transpiled, but when you don't want
|
|
334
|
-
* the changes to persist in the in-memory file.
|
|
335
|
-
*/
|
|
336
|
-
editor: Editor;
|
|
497
|
+
scope: Scope;
|
|
498
|
+
changedFiles?: BscFile[];
|
|
499
|
+
changedSymbols?: Map<SymbolTypeFlag, Set<string>>;
|
|
337
500
|
}
|
|
338
501
|
export interface AfterFileTranspileEvent<TFile extends BscFile = BscFile> {
|
|
339
502
|
/**
|
|
@@ -349,45 +512,150 @@ export interface AfterFileTranspileEvent<TFile extends BscFile = BscFile> {
|
|
|
349
512
|
/**
|
|
350
513
|
* The sourceMaps for the generated code (if emitting source maps is enabled)
|
|
351
514
|
*/
|
|
352
|
-
map?:
|
|
515
|
+
map?: string;
|
|
353
516
|
/**
|
|
354
517
|
* The generated type definition file contents (if emitting type definitions are enabled)
|
|
355
518
|
*/
|
|
356
519
|
typedef?: string;
|
|
520
|
+
}
|
|
521
|
+
export declare type BeforeProvideFileEvent<TFile extends BscFile = BscFile> = ProvideFileEvent<TFile>;
|
|
522
|
+
export interface ProvideFileEvent<TFile extends BscFile = BscFile> {
|
|
523
|
+
/**
|
|
524
|
+
* The lower-case file extension for the srcPath. (i.e. ".brs", ".xml")
|
|
525
|
+
*/
|
|
526
|
+
srcExtension: string;
|
|
357
527
|
/**
|
|
358
|
-
*
|
|
359
|
-
* restoring the objects to their prior state. This is useful for changing code right before a file gets transpiled, but when you don't want
|
|
360
|
-
* the changes to persist in the in-memory file.
|
|
528
|
+
* The srcPath for the file. (i.e. `/user/bob/projects/VideoApp/source/main.bs`)
|
|
361
529
|
*/
|
|
530
|
+
srcPath: string;
|
|
531
|
+
/**
|
|
532
|
+
* The destPath for the file. (i.e. for `/user/bob/projects/VideoApp/source/main.bs`, destPath would be `source/main.bs`)
|
|
533
|
+
*/
|
|
534
|
+
destPath: string;
|
|
535
|
+
/**
|
|
536
|
+
* A lazy-loading container for this file's data. Call `.get()` to lazy load the data, and `.set()` to override file contents
|
|
537
|
+
*/
|
|
538
|
+
data: LazyFileData;
|
|
539
|
+
/**
|
|
540
|
+
* An array of files that should be added to the program as a result of this event
|
|
541
|
+
*/
|
|
542
|
+
files: TFile[];
|
|
543
|
+
/**
|
|
544
|
+
* The program for this event
|
|
545
|
+
*/
|
|
546
|
+
program: Program;
|
|
547
|
+
/**
|
|
548
|
+
* A factory used to create new instances of the BrighterScript built-in file types. This mitigates the issue
|
|
549
|
+
* of a plugin's version of a File not being the same as the LanguageServer or CLI version of BrighterScript
|
|
550
|
+
* (due to npm installing multiple versions of brighterscript)
|
|
551
|
+
*/
|
|
552
|
+
fileFactory: FileFactory;
|
|
553
|
+
}
|
|
554
|
+
export declare type AfterProvideFileEvent<TFile extends BscFile = BscFile> = ProvideFileEvent<TFile>;
|
|
555
|
+
export interface BeforeFileAddEvent<TFile extends BscFile = BscFile> {
|
|
556
|
+
file: TFile;
|
|
557
|
+
program: Program;
|
|
558
|
+
}
|
|
559
|
+
export declare type AfterFileAddEvent<TFile extends BscFile = BscFile> = BeforeFileAddEvent<TFile>;
|
|
560
|
+
export interface BeforeFileRemoveEvent<TFile extends BscFile = BscFile> {
|
|
561
|
+
file: TFile;
|
|
562
|
+
program: Program;
|
|
563
|
+
}
|
|
564
|
+
export declare type AfterFileRemoveEvent<TFile extends BscFile = BscFile> = BeforeFileRemoveEvent<TFile>;
|
|
565
|
+
export declare type BeforePrepareProgramEvent = PrepareProgramEvent;
|
|
566
|
+
/**
|
|
567
|
+
* Event for when the program prepares itself for building
|
|
568
|
+
*/
|
|
569
|
+
export interface PrepareProgramEvent {
|
|
570
|
+
program: Program;
|
|
362
571
|
editor: Editor;
|
|
363
572
|
}
|
|
364
|
-
export
|
|
573
|
+
export declare type AfterPrepareProgramEvent = PrepareProgramEvent;
|
|
574
|
+
export declare type BeforePrepareFileEvent<TFile extends BscFile = BscFile> = PrepareFileEvent<TFile>;
|
|
575
|
+
/**
|
|
576
|
+
* Prepare the file for building
|
|
577
|
+
*/
|
|
578
|
+
export interface PrepareFileEvent<TFile extends BscFile = BscFile> {
|
|
365
579
|
program: Program;
|
|
366
|
-
file:
|
|
580
|
+
file: TFile;
|
|
581
|
+
editor: Editor;
|
|
582
|
+
}
|
|
583
|
+
export declare type OnPrepareFileEvent<TFile extends BscFile = BscFile> = PrepareFileEvent<TFile>;
|
|
584
|
+
export declare type AfterPrepareFileEvent<TFile extends BscFile = BscFile> = PrepareFileEvent<TFile>;
|
|
585
|
+
/**
|
|
586
|
+
* A container that holds the code, map, and typedef for serialized code files.
|
|
587
|
+
*/
|
|
588
|
+
export interface SerializedCodeFile {
|
|
589
|
+
code?: string;
|
|
590
|
+
map?: string;
|
|
591
|
+
typedef?: string;
|
|
367
592
|
}
|
|
368
|
-
export interface
|
|
593
|
+
export interface BeforeSerializeProgramEvent {
|
|
369
594
|
program: Program;
|
|
370
|
-
|
|
595
|
+
files: BscFile[];
|
|
596
|
+
result: Map<BscFile, SerializedFile[]>;
|
|
371
597
|
}
|
|
372
|
-
export
|
|
598
|
+
export declare type OnSerializeProgramEvent = BeforeSerializeProgramEvent;
|
|
599
|
+
export declare type AfterSerializeProgramEvent = BeforeSerializeProgramEvent;
|
|
600
|
+
/**
|
|
601
|
+
* During the `SerializeFile` events, this is how plugins will contribute file data for a specific file
|
|
602
|
+
*/
|
|
603
|
+
export interface SerializedFile {
|
|
604
|
+
/**
|
|
605
|
+
* The raw data for this file (i.e. a binary buffer for a .jpeg file, or the transpiled code for a .bs file)
|
|
606
|
+
*/
|
|
607
|
+
data: Buffer;
|
|
608
|
+
/**
|
|
609
|
+
* The pkgPath for this chunk of data.
|
|
610
|
+
*/
|
|
611
|
+
pkgPath: string;
|
|
612
|
+
}
|
|
613
|
+
export declare type BeforeSerializeFileEvent<TFile extends BscFile = BscFile> = SerializeFileEvent<TFile>;
|
|
614
|
+
export interface SerializeFileEvent<TFile extends BscFile = BscFile> {
|
|
373
615
|
program: Program;
|
|
374
|
-
file:
|
|
375
|
-
range: Range;
|
|
616
|
+
file: TFile;
|
|
376
617
|
/**
|
|
377
|
-
*
|
|
618
|
+
* The list of all files created across all the `SerializeFile` events.
|
|
619
|
+
* The key is the pkgPath of the file, and the
|
|
378
620
|
*/
|
|
379
|
-
|
|
380
|
-
codeActions: CodeAction[];
|
|
621
|
+
result: Map<TFile, SerializedFile[]>;
|
|
381
622
|
}
|
|
382
|
-
export
|
|
623
|
+
export declare type AfterSerializeFileEvent<TFile extends BscFile = BscFile> = SerializeFileEvent<TFile>;
|
|
624
|
+
export interface BeforeWriteProgramEvent {
|
|
625
|
+
program: Program;
|
|
626
|
+
stagingDir: string;
|
|
627
|
+
files: Map<BscFile, SerializedFile[]>;
|
|
628
|
+
}
|
|
629
|
+
export declare type AfterWriteProgramEvent = BeforeWriteProgramEvent;
|
|
630
|
+
export declare type BeforeWriteFileEvent = WriteFileEvent;
|
|
631
|
+
export interface WriteFileEvent {
|
|
632
|
+
program: Program;
|
|
633
|
+
file: SerializedFile;
|
|
634
|
+
/**
|
|
635
|
+
* The full path to where the file was (or will be) written to.
|
|
636
|
+
*/
|
|
637
|
+
outputPath: string;
|
|
638
|
+
/**
|
|
639
|
+
* A set of all files that have been properly written. Plugins should add any handled files to this list so future plugins don't write then again
|
|
640
|
+
*/
|
|
641
|
+
processedFiles: Set<SerializedFile>;
|
|
642
|
+
}
|
|
643
|
+
export declare type AfterWriteFileEvent = BeforeWriteFileEvent;
|
|
644
|
+
export interface TranspileObj {
|
|
383
645
|
file: BscFile;
|
|
646
|
+
/**
|
|
647
|
+
* The absolute path to where the file should be written during build. (i.e. somewhere inside the stagingDir)
|
|
648
|
+
*/
|
|
384
649
|
outputPath: string;
|
|
385
650
|
}
|
|
386
|
-
export interface
|
|
651
|
+
export interface BeforeFileDisposeEvent {
|
|
652
|
+
program: Program;
|
|
653
|
+
file: BscFile;
|
|
654
|
+
}
|
|
655
|
+
export declare type AfterFileDisposeEvent = BeforeFileDisposeEvent;
|
|
656
|
+
export interface BeforeProgramDisposeEvent {
|
|
387
657
|
program: Program;
|
|
388
|
-
scope: Scope;
|
|
389
658
|
}
|
|
390
|
-
export declare type Editor = Pick<AstEditor, 'addToArray' | 'hasChanges' | 'removeFromArray' | 'setArrayValue' | 'setProperty' | 'overrideTranspileResult' | 'arrayPop' | 'arrayPush' | 'arrayShift' | 'arraySplice' | 'arrayUnshift' | 'removeProperty' | 'edit'>;
|
|
391
659
|
export interface SemanticToken {
|
|
392
660
|
range: Range;
|
|
393
661
|
tokenType: SemanticTokenTypes;
|
|
@@ -400,10 +668,7 @@ export interface TypedefProvider {
|
|
|
400
668
|
getTypedef(state: TranspileState): Array<SourceNode | string>;
|
|
401
669
|
}
|
|
402
670
|
export declare type TranspileResult = Array<(string | SourceNode)>;
|
|
403
|
-
|
|
404
|
-
* @param srcPath The absolute path to the source file on disk
|
|
405
|
-
*/
|
|
406
|
-
export declare type FileResolver = (srcPath: string) => string | undefined | Thenable<string | undefined> | void;
|
|
671
|
+
export declare type FileResolver = (srcPath: string) => string | Buffer | undefined | Thenable<string | Buffer | undefined> | void;
|
|
407
672
|
export interface ExpressionInfo {
|
|
408
673
|
expressions: Expression[];
|
|
409
674
|
varExpressions: Expression[];
|
|
@@ -414,41 +679,66 @@ export interface FileLink<T> {
|
|
|
414
679
|
item: T;
|
|
415
680
|
file: BrsFile;
|
|
416
681
|
}
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
682
|
+
export interface ExtraSymbolData {
|
|
683
|
+
definingNode?: AstNode;
|
|
684
|
+
description?: string;
|
|
685
|
+
completionPriority?: number;
|
|
686
|
+
flags?: SymbolTypeFlag;
|
|
687
|
+
memberOfAncestor?: boolean;
|
|
688
|
+
}
|
|
689
|
+
export interface GetTypeOptions {
|
|
690
|
+
flags: SymbolTypeFlag;
|
|
691
|
+
typeChain?: TypeChainEntry[];
|
|
692
|
+
data?: ExtraSymbolData;
|
|
693
|
+
ignoreCall?: boolean;
|
|
694
|
+
onlyCacheResolvedTypes?: boolean;
|
|
695
|
+
ignoreCacheForRetrieval?: boolean;
|
|
696
|
+
}
|
|
697
|
+
export declare class TypeChainEntry {
|
|
698
|
+
name: string;
|
|
699
|
+
type: BscType;
|
|
700
|
+
range: Range;
|
|
701
|
+
separatorToken: Token;
|
|
702
|
+
data: ExtraSymbolData;
|
|
703
|
+
constructor(name: string, type: BscType, data: ExtraSymbolData, range: Range, separatorToken?: Token);
|
|
704
|
+
get isResolved(): boolean;
|
|
705
|
+
}
|
|
706
|
+
export interface TypeChainProcessResult {
|
|
707
|
+
itemName: string;
|
|
708
|
+
itemParentTypeName: string;
|
|
709
|
+
fullNameOfItem: string;
|
|
710
|
+
fullChainName: string;
|
|
711
|
+
range: Range;
|
|
712
|
+
containsDynamic: boolean;
|
|
713
|
+
}
|
|
714
|
+
export interface TypeCompatibilityData {
|
|
715
|
+
missingFields?: {
|
|
716
|
+
name: string;
|
|
717
|
+
expectedType: BscType;
|
|
718
|
+
}[];
|
|
719
|
+
fieldMismatches?: {
|
|
720
|
+
name: string;
|
|
721
|
+
expectedType: BscType;
|
|
722
|
+
actualType: BscType;
|
|
723
|
+
}[];
|
|
724
|
+
depth?: number;
|
|
725
|
+
}
|
|
726
|
+
export interface NamespaceContainer {
|
|
727
|
+
file: BscFile;
|
|
728
|
+
fullName: string;
|
|
729
|
+
fullNameLower: string;
|
|
730
|
+
parentNameLower: string;
|
|
731
|
+
nameParts: Identifier[];
|
|
732
|
+
nameRange: Range;
|
|
733
|
+
lastPartName: string;
|
|
734
|
+
lastPartNameLower: string;
|
|
735
|
+
functionStatements: Map<string, FunctionStatement>;
|
|
736
|
+
isTopLevel: boolean;
|
|
737
|
+
namespaceStatements?: NamespaceStatement[];
|
|
738
|
+
statements?: Statement[];
|
|
739
|
+
classStatements?: Map<string, ClassStatement>;
|
|
740
|
+
enumStatements?: Map<string, EnumStatement>;
|
|
741
|
+
constStatements?: Map<string, ConstStatement>;
|
|
742
|
+
namespaces?: Map<string, NamespaceContainer>;
|
|
743
|
+
symbolTable: SymbolTable;
|
|
454
744
|
}
|