@velarscript/compiler 0.10.1
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/LICENSE +201 -0
- package/README.md +70 -0
- package/dist/analyzer.d.ts +1175 -0
- package/dist/analyzer.d.ts.map +1 -0
- package/dist/analyzer.js +12130 -0
- package/dist/analyzer.js.map +1 -0
- package/dist/application-package-host.d.ts +28 -0
- package/dist/application-package-host.d.ts.map +1 -0
- package/dist/application-package-host.js +2 -0
- package/dist/application-package-host.js.map +1 -0
- package/dist/ast.d.ts +853 -0
- package/dist/ast.d.ts.map +1 -0
- package/dist/ast.js +245 -0
- package/dist/ast.js.map +1 -0
- package/dist/class-runtime.d.ts +6 -0
- package/dist/class-runtime.d.ts.map +1 -0
- package/dist/class-runtime.js +45 -0
- package/dist/class-runtime.js.map +1 -0
- package/dist/collection-lowering-runtime.d.ts +7 -0
- package/dist/collection-lowering-runtime.d.ts.map +1 -0
- package/dist/collection-lowering-runtime.js +952 -0
- package/dist/collection-lowering-runtime.js.map +1 -0
- package/dist/collection-runtime.d.ts +16 -0
- package/dist/collection-runtime.d.ts.map +1 -0
- package/dist/collection-runtime.js +231 -0
- package/dist/collection-runtime.js.map +1 -0
- package/dist/core-vocabulary.d.ts +141 -0
- package/dist/core-vocabulary.d.ts.map +1 -0
- package/dist/core-vocabulary.js +88 -0
- package/dist/core-vocabulary.js.map +1 -0
- package/dist/diagnostic.d.ts +42 -0
- package/dist/diagnostic.d.ts.map +1 -0
- package/dist/diagnostic.js +66 -0
- package/dist/diagnostic.js.map +1 -0
- package/dist/embedded-javascript.d.ts +74 -0
- package/dist/embedded-javascript.d.ts.map +1 -0
- package/dist/embedded-javascript.js +341 -0
- package/dist/embedded-javascript.js.map +1 -0
- package/dist/embedded-module.d.ts +11 -0
- package/dist/embedded-module.d.ts.map +1 -0
- package/dist/embedded-module.js +67 -0
- package/dist/embedded-module.js.map +1 -0
- package/dist/embedded-source.d.ts +19 -0
- package/dist/embedded-source.d.ts.map +1 -0
- package/dist/embedded-source.js +61 -0
- package/dist/embedded-source.js.map +1 -0
- package/dist/emitter.d.ts +188 -0
- package/dist/emitter.d.ts.map +1 -0
- package/dist/emitter.js +3254 -0
- package/dist/emitter.js.map +1 -0
- package/dist/error-runtime.d.ts +17 -0
- package/dist/error-runtime.d.ts.map +1 -0
- package/dist/error-runtime.js +109 -0
- package/dist/error-runtime.js.map +1 -0
- package/dist/extension.d.ts +373 -0
- package/dist/extension.d.ts.map +1 -0
- package/dist/extension.js +25 -0
- package/dist/extension.js.map +1 -0
- package/dist/formatter.d.ts +13 -0
- package/dist/formatter.d.ts.map +1 -0
- package/dist/formatter.js +1440 -0
- package/dist/formatter.js.map +1 -0
- package/dist/framework-host.d.ts +87 -0
- package/dist/framework-host.d.ts.map +1 -0
- package/dist/framework-host.js +2 -0
- package/dist/framework-host.js.map +1 -0
- package/dist/index.d.ts +75 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +932 -0
- package/dist/index.js.map +1 -0
- package/dist/interpolated-string.d.ts +47 -0
- package/dist/interpolated-string.d.ts.map +1 -0
- package/dist/interpolated-string.js +344 -0
- package/dist/interpolated-string.js.map +1 -0
- package/dist/json-runtime.d.ts +2 -0
- package/dist/json-runtime.d.ts.map +1 -0
- package/dist/json-runtime.js +193 -0
- package/dist/json-runtime.js.map +1 -0
- package/dist/language-guidance.d.ts +31 -0
- package/dist/language-guidance.d.ts.map +1 -0
- package/dist/language-guidance.js +187 -0
- package/dist/language-guidance.js.map +1 -0
- package/dist/lexer.d.ts +85 -0
- package/dist/lexer.d.ts.map +1 -0
- package/dist/lexer.js +1004 -0
- package/dist/lexer.js.map +1 -0
- package/dist/limits.d.ts +2 -0
- package/dist/limits.d.ts.map +1 -0
- package/dist/limits.js +2 -0
- package/dist/limits.js.map +1 -0
- package/dist/mechanical-fix.d.ts +26 -0
- package/dist/mechanical-fix.d.ts.map +1 -0
- package/dist/mechanical-fix.js +61 -0
- package/dist/mechanical-fix.js.map +1 -0
- package/dist/narrowing-runtime.d.ts +5 -0
- package/dist/narrowing-runtime.d.ts.map +1 -0
- package/dist/narrowing-runtime.js +27 -0
- package/dist/narrowing-runtime.js.map +1 -0
- package/dist/number-runtime.d.ts +3 -0
- package/dist/number-runtime.d.ts.map +1 -0
- package/dist/number-runtime.js +37 -0
- package/dist/number-runtime.js.map +1 -0
- package/dist/parser.d.ts +245 -0
- package/dist/parser.d.ts.map +1 -0
- package/dist/parser.js +3582 -0
- package/dist/parser.js.map +1 -0
- package/dist/primitive-runtime.d.ts +4 -0
- package/dist/primitive-runtime.d.ts.map +1 -0
- package/dist/primitive-runtime.js +39 -0
- package/dist/primitive-runtime.js.map +1 -0
- package/dist/promise-runtime.d.ts +6 -0
- package/dist/promise-runtime.d.ts.map +1 -0
- package/dist/promise-runtime.js +86 -0
- package/dist/promise-runtime.js.map +1 -0
- package/dist/reactive-bridge-runtime.d.ts +7 -0
- package/dist/reactive-bridge-runtime.d.ts.map +1 -0
- package/dist/reactive-bridge-runtime.js +112 -0
- package/dist/reactive-bridge-runtime.js.map +1 -0
- package/dist/runtime-abi.d.ts +24 -0
- package/dist/runtime-abi.d.ts.map +1 -0
- package/dist/runtime-abi.js +24 -0
- package/dist/runtime-abi.js.map +1 -0
- package/dist/semantic.d.ts +142 -0
- package/dist/semantic.d.ts.map +1 -0
- package/dist/semantic.js +845 -0
- package/dist/semantic.js.map +1 -0
- package/dist/source-names.d.ts +32 -0
- package/dist/source-names.d.ts.map +1 -0
- package/dist/source-names.js +101 -0
- package/dist/source-names.js.map +1 -0
- package/dist/source.d.ts +19 -0
- package/dist/source.d.ts.map +1 -0
- package/dist/source.js +64 -0
- package/dist/source.js.map +1 -0
- package/dist/text-runtime.d.ts +2 -0
- package/dist/text-runtime.d.ts.map +1 -0
- package/dist/text-runtime.js +285 -0
- package/dist/text-runtime.js.map +1 -0
- package/dist/token.d.ts +19 -0
- package/dist/token.d.ts.map +1 -0
- package/dist/token.js +51 -0
- package/dist/token.js.map +1 -0
- package/dist/type-registry-runtime.d.ts +7 -0
- package/dist/type-registry-runtime.d.ts.map +1 -0
- package/dist/type-registry-runtime.js +51 -0
- package/dist/type-registry-runtime.js.map +1 -0
- package/dist/type-validation-runtime.d.ts +17 -0
- package/dist/type-validation-runtime.d.ts.map +1 -0
- package/dist/type-validation-runtime.js +150 -0
- package/dist/type-validation-runtime.js.map +1 -0
- package/dist/types.d.ts +356 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +1170 -0
- package/dist/types.js.map +1 -0
- package/dist/utf8-runtime.d.ts +7 -0
- package/dist/utf8-runtime.d.ts.map +1 -0
- package/dist/utf8-runtime.js +43 -0
- package/dist/utf8-runtime.js.map +1 -0
- package/package.json +48 -0
|
@@ -0,0 +1,373 @@
|
|
|
1
|
+
import type { AnalysisContext, ClassInfo, FormReadField, LoweringHints } from "./analyzer.ts";
|
|
2
|
+
import type { Analyzer } from "./analyzer.ts";
|
|
3
|
+
import type { Expression, Program, Statement, TypeReference } from "./ast.ts";
|
|
4
|
+
import type { Diagnostic } from "./diagnostic.ts";
|
|
5
|
+
import type { Parser } from "./parser.ts";
|
|
6
|
+
import type { SourceText, Span } from "./source.ts";
|
|
7
|
+
import type { CompilerSemanticExtension, SemanticSymbol } from "./semantic.ts";
|
|
8
|
+
import type { Token } from "./token.ts";
|
|
9
|
+
import type { EnumInfo, ExtensionTypeSyntaxResolver, ExtensionValueType, GenericTypeInfo, ValueType } from "./types.ts";
|
|
10
|
+
export { expressionContainsDirectAwait } from "./ast.ts";
|
|
11
|
+
export { VELAR_CLASS_FIELD_MODULE, VELAR_CLASS_FIELD_MODULE_SOURCE, VELAR_CLASS_FIELD_RUNTIME } from "./class-runtime.ts";
|
|
12
|
+
export { VELAR_COLLECTION_HOST_EXPORTS, VELAR_COLLECTION_HOST_MODULE, VELAR_COLLECTION_HOST_MODULE_SOURCE, VELAR_COLLECTION_IDENTITY_RUNTIME, VELAR_COLLECTION_LIST_RUNTIME, VELAR_COLLECTION_RECORD_RUNTIME, VELAR_COLLECTION_SET_MAP_RUNTIME, VELAR_COLLECTION_TYPE_RUNTIME } from "./collection-runtime.ts";
|
|
13
|
+
export { VELAR_COLLECTION_LOWERING_DEPENDENCIES, VELAR_COLLECTION_LOWERING_EXPORTS, VELAR_COLLECTION_LOWERING_MODULE, VELAR_COLLECTION_LOWERING_MODULE_SOURCE, VELAR_COLLECTION_LOWERING_RUNTIME } from "./collection-lowering-runtime.ts";
|
|
14
|
+
export { JavaScriptEmitter } from "./emitter.ts";
|
|
15
|
+
export { scanOpaqueEmbeddedSource } from "./embedded-source.ts";
|
|
16
|
+
export type { OpaqueEmbeddedSourceScan } from "./embedded-source.ts";
|
|
17
|
+
export { findInterpolatedExpressionEnd, scanStringLiteral } from "./interpolated-string.ts";
|
|
18
|
+
export { VELAR_ERROR_NORMALIZATION_MODULE, VELAR_ERROR_NORMALIZATION_MODULE_SOURCE, VELAR_ERROR_NORMALIZATION_RUNTIME, VELAR_HOST_ERROR_NAMES, VELAR_HOST_ERROR_PATH_NAMES, VELAR_HOST_ERROR_RUNTIME } from "./error-runtime.ts";
|
|
19
|
+
export { VELAR_STRICT_JSON_RUNTIME } from "./json-runtime.ts";
|
|
20
|
+
export { VELAR_NUMBER_METHOD_RUNTIME } from "./number-runtime.ts";
|
|
21
|
+
export { VELAR_NARROWING_MODULE, VELAR_NARROWING_MODULE_SOURCE, VELAR_NARROWING_RUNTIME } from "./narrowing-runtime.ts";
|
|
22
|
+
export { VELAR_PRIMITIVE_METHOD_MODULE, VELAR_PRIMITIVE_METHOD_MODULE_SOURCE } from "./primitive-runtime.ts";
|
|
23
|
+
export { VELAR_PROMISE_NORMALIZATION_MODULE, VELAR_PROMISE_NORMALIZATION_MODULE_SOURCE, VELAR_PROMISE_NORMALIZATION_RUNTIME } from "./promise-runtime.ts";
|
|
24
|
+
export { VELAR_REACTIVE_BRIDGE_MODULE, VELAR_REACTIVE_BRIDGE_MODULE_SOURCE, VELAR_REACTIVE_BRIDGE_RUNTIME, VELAR_REACTIVE_COLLECTION_BRIDGE_RUNTIME } from "./reactive-bridge-runtime.ts";
|
|
25
|
+
export { VELAR_PROMISE_NORMALIZATION_REGISTRY_KEY, VELAR_RUNTIME_REGISTRY_KEY, VELAR_RUNTIME_SCHEMA_VERSION, VELAR_TYPE_REGISTRY_KEY } from "./runtime-abi.ts";
|
|
26
|
+
export { VELAR_TYPE_REGISTRY_RUNTIME } from "./type-registry-runtime.ts";
|
|
27
|
+
export { VELAR_RUNTIME_TYPE_COLLECTION_RUNTIME, VELAR_TYPE_VALIDATION_MODULE, VELAR_TYPE_VALIDATION_MODULE_SOURCE, VELAR_TYPE_VALIDATION_RUNTIME, VELAR_VALIDATION_ERROR_RUNTIME, } from "./type-validation-runtime.ts";
|
|
28
|
+
export { VELAR_TEXT_METHOD_RUNTIME } from "./text-runtime.ts";
|
|
29
|
+
export { VELAR_UTF8_RUNTIME } from "./utf8-runtime.ts";
|
|
30
|
+
export { Analyzer, TEXT_NAMESPACE_MEMBERS } from "./analyzer.ts";
|
|
31
|
+
export type { CoreExpression, CoreStatement, Expression, Parameter, Program, Statement, TypeReference, TypeSyntax, } from "./ast.ts";
|
|
32
|
+
export type { AnalysisContext, ClassField, ClassInfo, FormReadField, LoweringHints } from "./analyzer.ts";
|
|
33
|
+
export { Parser } from "./parser.ts";
|
|
34
|
+
export { spanIdentity } from "./source.ts";
|
|
35
|
+
export type { Span } from "./source.ts";
|
|
36
|
+
export type { ParseResult } from "./parser.ts";
|
|
37
|
+
export type { CompilerSemanticExtension, SemanticDeclareOptions, SemanticExtensionContext, SemanticFunctionLike } from "./semantic.ts";
|
|
38
|
+
export type { Token, TokenKind } from "./token.ts";
|
|
39
|
+
export { anyType, boolType, describeType, invalidType, isInvalidType, isAssignable, isReadonlyView, nullType, nonOptional, numberType, optionalOf, readonlyViewOf, stringType, unionOf, unknownType, } from "./types.ts";
|
|
40
|
+
export type { ExtensionTypeSyntaxResolver, ExtensionValueType, ExtensionTypeDisplay, ValueType } from "./types.ts";
|
|
41
|
+
export declare const VELAR_EXTENSION_PROTOCOL_VERSION: 1;
|
|
42
|
+
export type VelarExtensionKind = "application" | "capability" | "language";
|
|
43
|
+
/**
|
|
44
|
+
* Semantic identity of an installed Velar extension. npm owns package
|
|
45
|
+
* acquisition and version resolution; this contract owns compiler/runtime
|
|
46
|
+
* composition and therefore uses an API version independent of npm semver.
|
|
47
|
+
*/
|
|
48
|
+
export interface VelarExtensionContract {
|
|
49
|
+
readonly protocolVersion: typeof VELAR_EXTENSION_PROTOCOL_VERSION;
|
|
50
|
+
readonly apiVersion: string;
|
|
51
|
+
readonly kind: VelarExtensionKind;
|
|
52
|
+
readonly extends: Readonly<Record<string, string>>;
|
|
53
|
+
/**
|
|
54
|
+
* Application targets whose public compiler/runtime layers are assembled
|
|
55
|
+
* into this extension. Composition does not activate another application
|
|
56
|
+
* extension in the project graph; it records ownership and API provenance.
|
|
57
|
+
*/
|
|
58
|
+
readonly composes?: Readonly<Record<string, string>>;
|
|
59
|
+
}
|
|
60
|
+
export interface CompilerEmitter {
|
|
61
|
+
emit(program: Program): string;
|
|
62
|
+
sourceMap(source: SourceText): string;
|
|
63
|
+
/**
|
|
64
|
+
* Static JavaScript modules emitted beside the owning compiled `.vel`
|
|
65
|
+
* module. D53 uses this channel for embedded JavaScript: every block stays a
|
|
66
|
+
* real ESM file, so hosts can serve or bundle it without eval/data URLs and
|
|
67
|
+
* its own source map can point back into the authoring `.vel` file.
|
|
68
|
+
*/
|
|
69
|
+
embeddedModules?(source: SourceText): readonly CompilerEmbeddedJavaScriptModule[];
|
|
70
|
+
runtimeModules?(): readonly string[];
|
|
71
|
+
css?(): string;
|
|
72
|
+
styleSegments?(): CompilerStyleSegments;
|
|
73
|
+
}
|
|
74
|
+
export interface CompilerEmbeddedJavaScriptModule {
|
|
75
|
+
/** Relative ESM specifier written into the owning compiled module. */
|
|
76
|
+
readonly specifier: `./${string}.js`;
|
|
77
|
+
readonly code: string;
|
|
78
|
+
readonly sourceMap: string;
|
|
79
|
+
/** Authoring range of the raw JavaScript body in the owning `.vel` file. */
|
|
80
|
+
readonly sourceSpan: Span;
|
|
81
|
+
}
|
|
82
|
+
export interface CompilerEmitterOptions {
|
|
83
|
+
readonly sharedRuntimeModules?: boolean;
|
|
84
|
+
/** Authoring module path, used to derive collision-free sibling artifacts. */
|
|
85
|
+
readonly sourcePath?: string;
|
|
86
|
+
}
|
|
87
|
+
export interface CompilerStyleSegments {
|
|
88
|
+
readonly before: string;
|
|
89
|
+
readonly controlled: string;
|
|
90
|
+
readonly after: string;
|
|
91
|
+
}
|
|
92
|
+
export interface CompilerLexicalExtension {
|
|
93
|
+
/**
|
|
94
|
+
* Statement- and expression-head words the extension owns. D30 item 16 made
|
|
95
|
+
* them contextual: the lexer leaves them ordinary identifiers, so each stays
|
|
96
|
+
* available as a binding, parameter, field, or argument name, and the
|
|
97
|
+
* extension's parser claims one only where its declaration shape is
|
|
98
|
+
* unmistakable. Declaring the vocabulary here is what lets Core recognize an
|
|
99
|
+
* indentation-owned extension block and an editor document the word.
|
|
100
|
+
*/
|
|
101
|
+
readonly contextualKeywords?: ReadonlySet<string>;
|
|
102
|
+
readonly forbiddenIdentifiers?: Readonly<Record<string, string>>;
|
|
103
|
+
readonly numericSuffixes?: ReadonlySet<string>;
|
|
104
|
+
readonly scan?: (context: CompilerLexicalScanContext) => CompilerLexicalScanResult | null;
|
|
105
|
+
}
|
|
106
|
+
export interface CompilerLexicalScanContext {
|
|
107
|
+
readonly source: string;
|
|
108
|
+
readonly offset: number;
|
|
109
|
+
readonly currentIndent: number;
|
|
110
|
+
readonly tokens: readonly Token[];
|
|
111
|
+
}
|
|
112
|
+
export interface CompilerLexicalScanResult {
|
|
113
|
+
readonly token: Token;
|
|
114
|
+
readonly nextOffset: number;
|
|
115
|
+
readonly diagnostics?: readonly Diagnostic[];
|
|
116
|
+
readonly startsLine?: boolean;
|
|
117
|
+
}
|
|
118
|
+
export interface CompilerAnalysisExtension {
|
|
119
|
+
readonly primitiveTypes?: ReadonlySet<string>;
|
|
120
|
+
readonly primitiveParents?: ReadonlyMap<string, ReadonlySet<string>>;
|
|
121
|
+
readonly primitiveMutableFields?: ReadonlyMap<string, ReadonlySet<string>>;
|
|
122
|
+
readonly globals?: ReadonlyMap<string, ValueType>;
|
|
123
|
+
readonly reservedBindings?: ReadonlySet<string>;
|
|
124
|
+
readonly globalGuidance?: ReadonlyMap<string, string>;
|
|
125
|
+
/**
|
|
126
|
+
* Guidance that replaces `globalGuidance` inside a module whose path ends
|
|
127
|
+
* with the keyed suffix. The right door for a reserved global depends on
|
|
128
|
+
* where the author is standing: `document` inside a component means JSX and
|
|
129
|
+
* refs, and inside a `.browser.test.vel` it means `velar/web-test`.
|
|
130
|
+
*/
|
|
131
|
+
readonly globalGuidanceByPathSuffix?: ReadonlyMap<string, ReadonlyMap<string, string>>;
|
|
132
|
+
/**
|
|
133
|
+
* D52 rule 114: a namespace prefix the language invented and then withdrew,
|
|
134
|
+
* keyed by the retired name. It is `permanentNamespace` run backwards — that
|
|
135
|
+
* one turns an import into a prefix, this one turns a prefix back into the
|
|
136
|
+
* import — so the migration teaches the named import that replaced it and
|
|
137
|
+
* carries the mechanical rewrite (drop the prefix, add the import) with it.
|
|
138
|
+
*/
|
|
139
|
+
readonly retiredNamespaces?: ReadonlyMap<string, RetiredNamespace>;
|
|
140
|
+
/** Resolve target-owned type syntax without teaching Core the target's types. */
|
|
141
|
+
readonly resolveTypeSyntax?: ExtensionTypeSyntaxResolver;
|
|
142
|
+
/** Decide compatibility inside a target-owned type family. */
|
|
143
|
+
readonly isTypeAssignable?: (actual: ExtensionValueType, expected: ExtensionValueType, assign: (actual: ValueType, expected: ValueType) => boolean) => boolean | undefined;
|
|
144
|
+
/** Resolve target-owned runtime members; null means the target owns the type but the member is absent. */
|
|
145
|
+
readonly memberType?: (type: ExtensionValueType, property: string) => ValueType | null | undefined;
|
|
146
|
+
/**
|
|
147
|
+
* Declare whether a target-owned value has a total, hook-free text form.
|
|
148
|
+
* `true` admits the value to f-strings and `str()`, `false` records an owned
|
|
149
|
+
* rejection, and `undefined` leaves the type for another extension or Core.
|
|
150
|
+
*/
|
|
151
|
+
readonly textForm?: (type: ValueType) => boolean | undefined;
|
|
152
|
+
readonly inferIntrinsic?: (context: CompilerIntrinsicAnalysisContext) => ValueType | undefined;
|
|
153
|
+
/** Frame-aware traversal for expression nodes owned by this extension. */
|
|
154
|
+
readonly directAwaitExpression?: (expression: Expression, contains: (expression: Expression) => boolean) => boolean | undefined;
|
|
155
|
+
/** Frame-aware traversal for statement nodes owned by this extension. */
|
|
156
|
+
readonly directAwaitStatement?: (statement: Statement, containsExpression: (expression: Expression) => boolean, containsBlock: (statements: readonly Statement[]) => boolean) => boolean | undefined;
|
|
157
|
+
}
|
|
158
|
+
/** The module a retired namespace's members moved back to, and which names moved. */
|
|
159
|
+
export interface RetiredNamespace {
|
|
160
|
+
readonly module: string;
|
|
161
|
+
readonly members: ReadonlySet<string>;
|
|
162
|
+
}
|
|
163
|
+
export interface CompilerIntrinsicAnalysisContext {
|
|
164
|
+
readonly intrinsic: Extract<ValueType, {
|
|
165
|
+
kind: "intrinsic";
|
|
166
|
+
}>;
|
|
167
|
+
readonly argumentAt: (index: number) => Expression | null;
|
|
168
|
+
readonly callSpan: Span;
|
|
169
|
+
readonly arity: (minimum?: number, maximum?: number) => void;
|
|
170
|
+
readonly inferAt: (index: number, expected?: ValueType) => ValueType;
|
|
171
|
+
readonly callbackAt: (index: number, parameters: readonly ValueType[], result: ValueType) => ValueType;
|
|
172
|
+
readonly runtimeTypeAt: (index: number) => ValueType;
|
|
173
|
+
readonly typeError: (message: string, span: Span) => void;
|
|
174
|
+
readonly isAssignable: (actual: ValueType, expected: ValueType) => boolean;
|
|
175
|
+
readonly expandAliases: (type: ValueType) => ValueType;
|
|
176
|
+
readonly jsonSerializable: (type: ValueType) => boolean | null;
|
|
177
|
+
readonly isHttpFormBody: (type: ValueType) => boolean;
|
|
178
|
+
readonly declaredFieldsOf: (identity: string) => ReadonlyMap<string, ValueType> | null;
|
|
179
|
+
readonly formReadField: (name: string, type: ValueType, span: Span) => FormReadField | null;
|
|
180
|
+
readonly recordFormRead: (sourceSpan: Span, fields: readonly FormReadField[]) => void;
|
|
181
|
+
}
|
|
182
|
+
export interface CompilerModuleExtension {
|
|
183
|
+
readonly apiVersion?: string;
|
|
184
|
+
readonly interfaces: ReadonlyMap<string, ModuleInterface>;
|
|
185
|
+
readonly sources: ReadonlyMap<string, string>;
|
|
186
|
+
/**
|
|
187
|
+
* Runtime-module dependencies owned by the same extension module source.
|
|
188
|
+
* The CLI materializes this graph transitively for unbundled targets; a
|
|
189
|
+
* dependency is an implementation detail and does not publish an interface.
|
|
190
|
+
*/
|
|
191
|
+
readonly dependencies?: ReadonlyMap<string, readonly string[]>;
|
|
192
|
+
readonly source?: (specifier: string, projectConfig: unknown) => string | null;
|
|
193
|
+
}
|
|
194
|
+
export interface CompilerEditorCompletion {
|
|
195
|
+
readonly label: string;
|
|
196
|
+
readonly kind: number;
|
|
197
|
+
readonly detail?: string;
|
|
198
|
+
}
|
|
199
|
+
export interface CompilerProjectEditorCompletion {
|
|
200
|
+
readonly label: string;
|
|
201
|
+
readonly detail: string;
|
|
202
|
+
readonly kind: SemanticSymbol["kind"];
|
|
203
|
+
readonly documentation?: string;
|
|
204
|
+
readonly presentationKind?: SemanticSymbol["presentationKind"];
|
|
205
|
+
}
|
|
206
|
+
export interface CompilerProjectEditorCompletionContext {
|
|
207
|
+
readonly source: string;
|
|
208
|
+
readonly offset: number;
|
|
209
|
+
readonly visibleSymbols: readonly CompilerProjectEditorCompletion[];
|
|
210
|
+
readonly membersAt: (offset: number) => readonly CompilerProjectEditorCompletion[];
|
|
211
|
+
}
|
|
212
|
+
export interface CompilerProjectEditorCompletionResult {
|
|
213
|
+
readonly context: string;
|
|
214
|
+
readonly completions: readonly CompilerProjectEditorCompletion[];
|
|
215
|
+
}
|
|
216
|
+
export interface CompilerProjectEditorRenameContext {
|
|
217
|
+
readonly name: string;
|
|
218
|
+
readonly kind: SemanticSymbol["kind"];
|
|
219
|
+
readonly container: string | null;
|
|
220
|
+
readonly containerKind: SemanticSymbol["kind"] | null;
|
|
221
|
+
}
|
|
222
|
+
export interface CompilerProjectEditorExtension {
|
|
223
|
+
readonly complete?: (context: CompilerProjectEditorCompletionContext) => CompilerProjectEditorCompletionResult | undefined;
|
|
224
|
+
readonly protectRename?: (context: CompilerProjectEditorRenameContext) => string | undefined;
|
|
225
|
+
}
|
|
226
|
+
export interface CompilerEditorExtension {
|
|
227
|
+
readonly keywordDocumentation?: Readonly<Record<string, string>>;
|
|
228
|
+
readonly typeDocumentation?: Readonly<Record<string, string>>;
|
|
229
|
+
readonly completions?: readonly CompilerEditorCompletion[];
|
|
230
|
+
readonly project?: CompilerProjectEditorExtension;
|
|
231
|
+
}
|
|
232
|
+
export interface CompilerFormattingExtension {
|
|
233
|
+
/** Preserve one target-owned angle-bracket embedding while formatting its host line. */
|
|
234
|
+
readonly angleBracketEmbedding?: {
|
|
235
|
+
readonly voidElements?: ReadonlySet<string>;
|
|
236
|
+
};
|
|
237
|
+
/**
|
|
238
|
+
* Claim a target-owned opaque source region beginning at `start`. The
|
|
239
|
+
* formatter preserves every byte through `end`; recognizing the header and
|
|
240
|
+
* structural closing delimiter remains the owning extension's job.
|
|
241
|
+
*/
|
|
242
|
+
readonly scanOpaqueSource?: (source: string, start: number) => CompilerFormattingOpaqueSourceScan | null;
|
|
243
|
+
}
|
|
244
|
+
export interface CompilerFormattingOpaqueSourceScan {
|
|
245
|
+
/** Exclusive end offset of the complete opaque region. */
|
|
246
|
+
readonly end: number;
|
|
247
|
+
/** Whether the opening delimiter is written directly against its header. */
|
|
248
|
+
readonly attachedToPrevious: boolean;
|
|
249
|
+
}
|
|
250
|
+
export interface CompilerInterfaceContext {
|
|
251
|
+
readonly exports: Map<string, ValueType>;
|
|
252
|
+
readonly reactiveExports: Map<string, "state">;
|
|
253
|
+
readonly extensionExports: Map<string, unknown>;
|
|
254
|
+
readonly resolve: (reference: TypeReference | null) => ValueType;
|
|
255
|
+
readonly inferPublicExpression: (expression: Expression) => ValueType;
|
|
256
|
+
readonly bindingType: (name: string, spanStart: number) => ValueType | null;
|
|
257
|
+
readonly unresolvedInferredResult: ValueType;
|
|
258
|
+
}
|
|
259
|
+
export interface CompilerInspectionExtension {
|
|
260
|
+
readonly contributeInterface?: (statement: Statement, context: CompilerInterfaceContext) => boolean;
|
|
261
|
+
/**
|
|
262
|
+
* Whole-program annotations for exported names, merged into the module
|
|
263
|
+
* interface's extension exports under this extension's id. Unlike
|
|
264
|
+
* contributeInterface, this hook also reaches exports the core interface
|
|
265
|
+
* builder owns (functions, consts), so an extension can attach metadata —
|
|
266
|
+
* such as purity markers — without taking over their typing.
|
|
267
|
+
*/
|
|
268
|
+
readonly exportAnnotations?: (program: Program) => ReadonlyMap<string, unknown>;
|
|
269
|
+
readonly interfaceExportIdentity?: (name: string, value: unknown) => string;
|
|
270
|
+
readonly inferPublicExpression?: (expression: Expression) => ValueType | undefined;
|
|
271
|
+
readonly resources?: (program: Program) => readonly CompilerResourceDependency[];
|
|
272
|
+
readonly moduleData?: (program: Program, path: string) => unknown;
|
|
273
|
+
}
|
|
274
|
+
export interface CompilerResourceDependency {
|
|
275
|
+
readonly source: string;
|
|
276
|
+
readonly kind: string;
|
|
277
|
+
}
|
|
278
|
+
export interface CompilerParserFactory {
|
|
279
|
+
readonly create: (tokens: readonly Token[], lexicalExtensions: readonly CompilerLexicalExtension[]) => Parser;
|
|
280
|
+
}
|
|
281
|
+
export interface CompilerAnalyzerFactory {
|
|
282
|
+
readonly create: (context: AnalysisContext, extensions: readonly CompilerAnalysisExtension[]) => Analyzer;
|
|
283
|
+
}
|
|
284
|
+
export interface ModuleTest {
|
|
285
|
+
readonly name: string;
|
|
286
|
+
readonly title: string;
|
|
287
|
+
}
|
|
288
|
+
export interface ModuleInterface {
|
|
289
|
+
readonly exports: ReadonlyMap<string, ValueType>;
|
|
290
|
+
readonly mutableExports: ReadonlySet<string>;
|
|
291
|
+
/**
|
|
292
|
+
* Exports whose bare read lowers through `.get()` in the importing module.
|
|
293
|
+
* D71 rule 184 put both halves of the reactive row here, so `"state"` is a
|
|
294
|
+
* marker for *reactive*, not the word the author wrote — a derived `computed`
|
|
295
|
+
* carries the same marker. Never render it into a diagnostic as a noun.
|
|
296
|
+
*/
|
|
297
|
+
readonly reactiveExports: ReadonlyMap<string, "state">;
|
|
298
|
+
/** Named re-exports (`export {name} from "source"`), keyed by the exported alias. */
|
|
299
|
+
readonly reExports: ReadonlyMap<string, {
|
|
300
|
+
readonly source: string;
|
|
301
|
+
readonly imported: string;
|
|
302
|
+
}>;
|
|
303
|
+
/**
|
|
304
|
+
* Exports whose emitted binding is hoisted and initialized when the module is
|
|
305
|
+
* linked rather than when its body runs — function declarations only. A
|
|
306
|
+
* cycle member may read one of these before the defining module evaluates;
|
|
307
|
+
* every other export shape is in its temporal dead zone until then (D31
|
|
308
|
+
* item 23).
|
|
309
|
+
*/
|
|
310
|
+
readonly hoistedExports?: ReadonlySet<string>;
|
|
311
|
+
readonly namedTypes: ReadonlyMap<string, ReadonlyMap<string, ValueType>>;
|
|
312
|
+
readonly namedTypeReadonlyFields?: ReadonlyMap<string, ReadonlySet<string>>;
|
|
313
|
+
readonly namedTypeIdentities: ReadonlyMap<string, string>;
|
|
314
|
+
/**
|
|
315
|
+
* D55 rule 120: the module's generic record declarations. A generic type has
|
|
316
|
+
* no field table of its own — it has one per instantiation — so it is
|
|
317
|
+
* published as a template a dependent applies to arguments the declaring
|
|
318
|
+
* module never saw, rather than through `namedTypes`.
|
|
319
|
+
*/
|
|
320
|
+
readonly genericTypes?: ReadonlyMap<string, GenericTypeInfo>;
|
|
321
|
+
readonly typeAliases: ReadonlyMap<string, ValueType>;
|
|
322
|
+
readonly enums: ReadonlyMap<string, EnumInfo>;
|
|
323
|
+
readonly classes: ReadonlyMap<string, ClassInfo>;
|
|
324
|
+
/**
|
|
325
|
+
* D39 item 53: the module's `test "name":` declarations. `name` is the
|
|
326
|
+
* emitted function the runner calls; `title` is the author's name for the
|
|
327
|
+
* test, which the reporter quotes verbatim.
|
|
328
|
+
*/
|
|
329
|
+
readonly tests: readonly ModuleTest[];
|
|
330
|
+
readonly extensionExports: ReadonlyMap<string, ReadonlyMap<string, unknown>>;
|
|
331
|
+
readonly extensionData: ReadonlyMap<string, unknown>;
|
|
332
|
+
}
|
|
333
|
+
/**
|
|
334
|
+
* D56 rule 129 — the statement forms this extension's parser can produce.
|
|
335
|
+
*
|
|
336
|
+
* Core publishes its own roster as `CORE_STATEMENT_CONSTRUCTS`, derived from
|
|
337
|
+
* the `CoreStatement` union by a mapped type; an extension's statements never
|
|
338
|
+
* enter that union, so an extension that owns syntax has to hand its roster
|
|
339
|
+
* across. Without this slot the tour-coverage gate could only require *names* —
|
|
340
|
+
* keywords, exports, properties — and a construct spelled out of keywords the
|
|
341
|
+
* tour already covers is invisible to a name-by-name check. Registering a
|
|
342
|
+
* `parser` without a `syntax` is therefore a gate failure, not a default.
|
|
343
|
+
*/
|
|
344
|
+
export interface CompilerSyntaxExtension {
|
|
345
|
+
/** Construct key → the source spelling a reader would write, for failures. */
|
|
346
|
+
readonly statementConstructs: Readonly<Record<string, string>>;
|
|
347
|
+
/**
|
|
348
|
+
* The construct key of one parsed node, or null when this extension does not
|
|
349
|
+
* own it. A key may refine the node kind — the Web extension's `unsafe css`
|
|
350
|
+
* splits on the tagged union its `source` field already carries — so the
|
|
351
|
+
* roster above is keyed by what this returns, not by node kind.
|
|
352
|
+
*/
|
|
353
|
+
statementConstructKey(node: {
|
|
354
|
+
readonly kind: string;
|
|
355
|
+
}): string | null;
|
|
356
|
+
}
|
|
357
|
+
export interface CompilerExtension {
|
|
358
|
+
readonly id: string;
|
|
359
|
+
readonly contract?: VelarExtensionContract;
|
|
360
|
+
readonly capabilities?: readonly string[];
|
|
361
|
+
readonly lexical?: CompilerLexicalExtension;
|
|
362
|
+
readonly syntax?: CompilerSyntaxExtension;
|
|
363
|
+
readonly analysis?: CompilerAnalysisExtension;
|
|
364
|
+
readonly modules?: CompilerModuleExtension;
|
|
365
|
+
readonly editor?: CompilerEditorExtension;
|
|
366
|
+
readonly formatting?: CompilerFormattingExtension;
|
|
367
|
+
readonly parser?: CompilerParserFactory;
|
|
368
|
+
readonly analyzer?: CompilerAnalyzerFactory;
|
|
369
|
+
readonly semantic?: CompilerSemanticExtension;
|
|
370
|
+
readonly inspection?: CompilerInspectionExtension;
|
|
371
|
+
createEmitter?(hints: LoweringHints, forcedFunctionExports: ReadonlySet<string>, resourceContents: ReadonlyMap<string, string>, extensionImports: ReadonlyMap<string, ReadonlyMap<string, unknown>>, options: CompilerEmitterOptions): CompilerEmitter;
|
|
372
|
+
}
|
|
373
|
+
//# sourceMappingURL=extension.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extension.d.ts","sourceRoot":"","sources":["../src/extension.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,SAAS,EAAE,aAAa,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAC9F,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AAC9C,OAAO,KAAK,EAAiC,UAAU,EAAa,OAAO,EAAE,SAAS,EAAE,aAAa,EAAc,MAAM,UAAU,CAAC;AACpI,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,KAAK,EAAE,UAAU,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AACpD,OAAO,KAAK,EAAE,yBAAyB,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC/E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACxC,OAAO,KAAK,EAAE,QAAQ,EAAE,2BAA2B,EAAE,kBAAk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2B,CAAC;IAClD,QAAQ,CAAC,MAAM,CAAC,EAAE,qBAAqB,CAAC;IACxC,QAAQ,CAAC,QAAQ,CAAC,EAAE,uBAAuB,CAAC;IAC5C,QAAQ,CAAC,QAAQ,CAAC,EAAE,yBAAyB,CAAC;IAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,2BAA2B,CAAC;IAClD,aAAa,CAAC,CACZ,KAAK,EAAE,aAAa,EACpB,qBAAqB,EAAE,WAAW,CAAC,MAAM,CAAC,EAC1C,gBAAgB,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,CAAC,EAC7C,gBAAgB,EAAE,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC,EACnE,OAAO,EAAE,sBAAsB,GAC9B,eAAe,CAAC;CACpB"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export { expressionContainsDirectAwait } from "./ast.js";
|
|
2
|
+
export { VELAR_CLASS_FIELD_MODULE, VELAR_CLASS_FIELD_MODULE_SOURCE, VELAR_CLASS_FIELD_RUNTIME } from "./class-runtime.js";
|
|
3
|
+
export { VELAR_COLLECTION_HOST_EXPORTS, VELAR_COLLECTION_HOST_MODULE, VELAR_COLLECTION_HOST_MODULE_SOURCE, VELAR_COLLECTION_IDENTITY_RUNTIME, VELAR_COLLECTION_LIST_RUNTIME, VELAR_COLLECTION_RECORD_RUNTIME, VELAR_COLLECTION_SET_MAP_RUNTIME, VELAR_COLLECTION_TYPE_RUNTIME } from "./collection-runtime.js";
|
|
4
|
+
export { VELAR_COLLECTION_LOWERING_DEPENDENCIES, VELAR_COLLECTION_LOWERING_EXPORTS, VELAR_COLLECTION_LOWERING_MODULE, VELAR_COLLECTION_LOWERING_MODULE_SOURCE, VELAR_COLLECTION_LOWERING_RUNTIME } from "./collection-lowering-runtime.js";
|
|
5
|
+
export { JavaScriptEmitter } from "./emitter.js";
|
|
6
|
+
export { scanOpaqueEmbeddedSource } from "./embedded-source.js";
|
|
7
|
+
export { findInterpolatedExpressionEnd, scanStringLiteral } from "./interpolated-string.js";
|
|
8
|
+
export { VELAR_ERROR_NORMALIZATION_MODULE, VELAR_ERROR_NORMALIZATION_MODULE_SOURCE, VELAR_ERROR_NORMALIZATION_RUNTIME, VELAR_HOST_ERROR_NAMES, VELAR_HOST_ERROR_PATH_NAMES, VELAR_HOST_ERROR_RUNTIME } from "./error-runtime.js";
|
|
9
|
+
export { VELAR_STRICT_JSON_RUNTIME } from "./json-runtime.js";
|
|
10
|
+
export { VELAR_NUMBER_METHOD_RUNTIME } from "./number-runtime.js";
|
|
11
|
+
export { VELAR_NARROWING_MODULE, VELAR_NARROWING_MODULE_SOURCE, VELAR_NARROWING_RUNTIME } from "./narrowing-runtime.js";
|
|
12
|
+
export { VELAR_PRIMITIVE_METHOD_MODULE, VELAR_PRIMITIVE_METHOD_MODULE_SOURCE } from "./primitive-runtime.js";
|
|
13
|
+
export { VELAR_PROMISE_NORMALIZATION_MODULE, VELAR_PROMISE_NORMALIZATION_MODULE_SOURCE, VELAR_PROMISE_NORMALIZATION_RUNTIME } from "./promise-runtime.js";
|
|
14
|
+
export { VELAR_REACTIVE_BRIDGE_MODULE, VELAR_REACTIVE_BRIDGE_MODULE_SOURCE, VELAR_REACTIVE_BRIDGE_RUNTIME, VELAR_REACTIVE_COLLECTION_BRIDGE_RUNTIME } from "./reactive-bridge-runtime.js";
|
|
15
|
+
export { VELAR_PROMISE_NORMALIZATION_REGISTRY_KEY, VELAR_RUNTIME_REGISTRY_KEY, VELAR_RUNTIME_SCHEMA_VERSION, VELAR_TYPE_REGISTRY_KEY } from "./runtime-abi.js";
|
|
16
|
+
export { VELAR_TYPE_REGISTRY_RUNTIME } from "./type-registry-runtime.js";
|
|
17
|
+
export { VELAR_RUNTIME_TYPE_COLLECTION_RUNTIME, VELAR_TYPE_VALIDATION_MODULE, VELAR_TYPE_VALIDATION_MODULE_SOURCE, VELAR_TYPE_VALIDATION_RUNTIME, VELAR_VALIDATION_ERROR_RUNTIME, } from "./type-validation-runtime.js";
|
|
18
|
+
export { VELAR_TEXT_METHOD_RUNTIME } from "./text-runtime.js";
|
|
19
|
+
export { VELAR_UTF8_RUNTIME } from "./utf8-runtime.js";
|
|
20
|
+
export { Analyzer, TEXT_NAMESPACE_MEMBERS } from "./analyzer.js";
|
|
21
|
+
export { Parser } from "./parser.js";
|
|
22
|
+
export { spanIdentity } from "./source.js";
|
|
23
|
+
export { anyType, boolType, describeType, invalidType, isInvalidType, isAssignable, isReadonlyView, nullType, nonOptional, numberType, optionalOf, readonlyViewOf, stringType, unionOf, unknownType, } from "./types.js";
|
|
24
|
+
export const VELAR_EXTENSION_PROTOCOL_VERSION = 1;
|
|
25
|
+
//# sourceMappingURL=extension.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"extension.js","sourceRoot":"","sources":["../src/extension.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,6BAA6B,EAAE,MAAM,UAAU,CAAC;AACzD,OAAO,EAAE,wBAAwB,EAAE,+BAA+B,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;AAC1H,OAAO,EAAE,6BAA6B,EAAE,4BAA4B,EAAE,mCAAmC,EAAE,iCAAiC,EAAE,6BAA6B,EAAE,+BAA+B,EAAE,gCAAgC,EAAE,6BAA6B,EAAE,MAAM,yBAAyB,CAAC;AAC/S,OAAO,EAAE,sCAAsC,EAAE,iCAAiC,EAAE,gCAAgC,EAAE,uCAAuC,EAAE,iCAAiC,EAAE,MAAM,kCAAkC,CAAC;AAC3O,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAEhE,OAAO,EAAE,6BAA6B,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAC5F,OAAO,EAAE,gCAAgC,EAAE,uCAAuC,EAAE,iCAAiC,EAAE,sBAAsB,EAAE,2BAA2B,EAAE,wBAAw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AgC,GAAG,CAAU,CAAC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { CompilerExtension } from "./extension.ts";
|
|
2
|
+
export interface FormatOptions {
|
|
3
|
+
readonly indentWidth?: number;
|
|
4
|
+
readonly extensions?: readonly CompilerExtension[];
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Formats VelarScript source without round-tripping through generated JavaScript.
|
|
8
|
+
* The formatter tokenizes each logical source line so strings, comments,
|
|
9
|
+
* extension-owned embeddings and literals, operators, named arguments, and
|
|
10
|
+
* type syntax retain their meaning while whitespace becomes canonical.
|
|
11
|
+
*/
|
|
12
|
+
export declare function formatSource(text: string, options?: FormatOptions): string;
|
|
13
|
+
//# sourceMappingURL=formatter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatter.d.ts","sourceRoot":"","sources":["../src/formatter.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAsC,MAAM,gBAAgB,CAAC;AAI5F,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,UAAU,CAAC,EAAE,SAAS,iBAAiB,EAAE,CAAC;CACpD;AAgCD;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,GAAE,aAAkB,GAAG,MAAM,CAmE9E"}
|