@rcrsr/rill 0.9.0 → 0.11.0
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/dist/ast-nodes.d.ts +43 -10
- package/dist/ast-nodes.d.ts.map +1 -1
- package/dist/ast-unions.d.ts +1 -1
- package/dist/ast-unions.d.ts.map +1 -1
- package/dist/constants.d.ts +1 -1
- package/dist/constants.d.ts.map +1 -1
- package/dist/constants.js +1 -0
- package/dist/constants.js.map +1 -1
- package/dist/error-registry.d.ts.map +1 -1
- package/dist/error-registry.js +273 -6
- package/dist/error-registry.js.map +1 -1
- package/dist/ext/crypto/index.d.ts.map +1 -1
- package/dist/ext/crypto/index.js +23 -12
- package/dist/ext/crypto/index.js.map +1 -1
- package/dist/ext/exec/index.d.ts.map +1 -1
- package/dist/ext/exec/index.js +10 -11
- package/dist/ext/exec/index.js.map +1 -1
- package/dist/ext/fetch/index.d.ts.map +1 -1
- package/dist/ext/fetch/index.js +15 -15
- package/dist/ext/fetch/index.js.map +1 -1
- package/dist/ext/fs/index.d.ts.map +1 -1
- package/dist/ext/fs/index.js +139 -47
- package/dist/ext/fs/index.js.map +1 -1
- package/dist/ext/kv/index.d.ts.map +1 -1
- package/dist/ext/kv/index.js +130 -31
- package/dist/ext/kv/index.js.map +1 -1
- package/dist/generated/introspection-data.d.ts +1 -1
- package/dist/generated/introspection-data.d.ts.map +1 -1
- package/dist/generated/introspection-data.js +109 -8
- package/dist/generated/introspection-data.js.map +1 -1
- package/dist/generated/version-data.d.ts +1 -1
- package/dist/generated/version-data.d.ts.map +1 -1
- package/dist/generated/version-data.js +2 -2
- package/dist/generated/version-data.js.map +1 -1
- package/dist/highlight-map.d.ts.map +1 -1
- package/dist/highlight-map.js +1 -0
- package/dist/highlight-map.js.map +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/lexer/readers.d.ts.map +1 -1
- package/dist/lexer/readers.js +1 -0
- package/dist/lexer/readers.js.map +1 -1
- package/dist/parser/index.d.ts +3 -1
- package/dist/parser/index.d.ts.map +1 -1
- package/dist/parser/index.js +4 -1
- package/dist/parser/index.js.map +1 -1
- package/dist/parser/parser-control.d.ts +1 -1
- package/dist/parser/parser-control.d.ts.map +1 -1
- package/dist/parser/parser-control.js +2 -2
- package/dist/parser/parser-control.js.map +1 -1
- package/dist/parser/parser-expr.d.ts +2 -1
- package/dist/parser/parser-expr.d.ts.map +1 -1
- package/dist/parser/parser-expr.js +15 -2
- package/dist/parser/parser-expr.js.map +1 -1
- package/dist/parser/parser-extract.d.ts.map +1 -1
- package/dist/parser/parser-extract.js +10 -9
- package/dist/parser/parser-extract.js.map +1 -1
- package/dist/parser/parser-functions.js +11 -6
- package/dist/parser/parser-functions.js.map +1 -1
- package/dist/parser/parser-literals.d.ts +1 -1
- package/dist/parser/parser-literals.d.ts.map +1 -1
- package/dist/parser/parser-literals.js +61 -7
- package/dist/parser/parser-literals.js.map +1 -1
- package/dist/parser/parser-types.d.ts +22 -6
- package/dist/parser/parser-types.d.ts.map +1 -1
- package/dist/parser/parser-types.js +126 -9
- package/dist/parser/parser-types.js.map +1 -1
- package/dist/parser/parser-use.d.ts +11 -0
- package/dist/parser/parser-use.d.ts.map +1 -0
- package/dist/parser/parser-use.js +68 -0
- package/dist/parser/parser-use.js.map +1 -0
- package/dist/parser/parser-variables.d.ts.map +1 -1
- package/dist/parser/parser-variables.js +5 -4
- package/dist/parser/parser-variables.js.map +1 -1
- package/dist/runtime/core/callable.d.ts +59 -70
- package/dist/runtime/core/callable.d.ts.map +1 -1
- package/dist/runtime/core/callable.js +37 -93
- package/dist/runtime/core/callable.js.map +1 -1
- package/dist/runtime/core/context.d.ts.map +1 -1
- package/dist/runtime/core/context.js +104 -33
- package/dist/runtime/core/context.js.map +1 -1
- package/dist/runtime/core/equals.d.ts.map +1 -1
- package/dist/runtime/core/equals.js +59 -17
- package/dist/runtime/core/equals.js.map +1 -1
- package/dist/runtime/core/eval/evaluator.d.ts.map +1 -1
- package/dist/runtime/core/eval/evaluator.js +2 -1
- package/dist/runtime/core/eval/evaluator.js.map +1 -1
- package/dist/runtime/core/eval/index.d.ts +2 -2
- package/dist/runtime/core/eval/index.d.ts.map +1 -1
- package/dist/runtime/core/eval/index.js +5 -0
- package/dist/runtime/core/eval/index.js.map +1 -1
- package/dist/runtime/core/eval/mixins/closures.d.ts +3 -5
- package/dist/runtime/core/eval/mixins/closures.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/closures.js +76 -40
- package/dist/runtime/core/eval/mixins/closures.js.map +1 -1
- package/dist/runtime/core/eval/mixins/collections.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/collections.js +4 -2
- package/dist/runtime/core/eval/mixins/collections.js.map +1 -1
- package/dist/runtime/core/eval/mixins/conversion.d.ts +9 -9
- package/dist/runtime/core/eval/mixins/conversion.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/conversion.js +51 -21
- package/dist/runtime/core/eval/mixins/conversion.js.map +1 -1
- package/dist/runtime/core/eval/mixins/core.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/core.js +8 -2
- package/dist/runtime/core/eval/mixins/core.js.map +1 -1
- package/dist/runtime/core/eval/mixins/extraction.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/extraction.js +20 -8
- package/dist/runtime/core/eval/mixins/extraction.js.map +1 -1
- package/dist/runtime/core/eval/mixins/literals.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/literals.js +32 -15
- package/dist/runtime/core/eval/mixins/literals.js.map +1 -1
- package/dist/runtime/core/eval/mixins/types.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/types.js +166 -21
- package/dist/runtime/core/eval/mixins/types.js.map +1 -1
- package/dist/runtime/core/eval/mixins/use.d.ts +25 -0
- package/dist/runtime/core/eval/mixins/use.d.ts.map +1 -0
- package/dist/runtime/core/eval/mixins/use.js +152 -0
- package/dist/runtime/core/eval/mixins/use.js.map +1 -0
- package/dist/runtime/core/eval/mixins/variables.d.ts.map +1 -1
- package/dist/runtime/core/eval/mixins/variables.js +67 -32
- package/dist/runtime/core/eval/mixins/variables.js.map +1 -1
- package/dist/runtime/core/execute.d.ts.map +1 -1
- package/dist/runtime/core/execute.js +11 -1
- package/dist/runtime/core/execute.js.map +1 -1
- package/dist/runtime/core/field-descriptor.d.ts +6 -6
- package/dist/runtime/core/field-descriptor.d.ts.map +1 -1
- package/dist/runtime/core/field-descriptor.js +2 -2
- package/dist/runtime/core/field-descriptor.js.map +1 -1
- package/dist/runtime/core/introspection.d.ts +16 -0
- package/dist/runtime/core/introspection.d.ts.map +1 -1
- package/dist/runtime/core/introspection.js +102 -7
- package/dist/runtime/core/introspection.js.map +1 -1
- package/dist/runtime/core/resolvers.d.ts +39 -0
- package/dist/runtime/core/resolvers.d.ts.map +1 -0
- package/dist/runtime/core/resolvers.js +89 -0
- package/dist/runtime/core/resolvers.js.map +1 -0
- package/dist/runtime/core/types.d.ts +54 -5
- package/dist/runtime/core/types.d.ts.map +1 -1
- package/dist/runtime/core/types.js.map +1 -1
- package/dist/runtime/core/values.d.ts +43 -29
- package/dist/runtime/core/values.d.ts.map +1 -1
- package/dist/runtime/core/values.js +153 -68
- package/dist/runtime/core/values.js.map +1 -1
- package/dist/runtime/ext/builtins.d.ts +3 -4
- package/dist/runtime/ext/builtins.d.ts.map +1 -1
- package/dist/runtime/ext/builtins.js +621 -444
- package/dist/runtime/ext/builtins.js.map +1 -1
- package/dist/runtime/ext/extensions.d.ts +43 -43
- package/dist/runtime/ext/extensions.d.ts.map +1 -1
- package/dist/runtime/ext/extensions.js.map +1 -1
- package/dist/runtime/index.d.ts +8 -5
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/index.js +6 -2
- package/dist/runtime/index.js.map +1 -1
- package/dist/signature-parser.d.ts +43 -0
- package/dist/signature-parser.d.ts.map +1 -0
- package/dist/signature-parser.js +289 -0
- package/dist/signature-parser.js.map +1 -0
- package/dist/token-types.d.ts +1 -0
- package/dist/token-types.d.ts.map +1 -1
- package/dist/token-types.js +1 -0
- package/dist/token-types.js.map +1 -1
- package/dist/value-types.d.ts +20 -6
- package/dist/value-types.d.ts.map +1 -1
- package/dist/value-types.js +1 -1
- package/dist/value-types.js.map +1 -1
- package/package.json +4 -1
|
@@ -17,16 +17,11 @@
|
|
|
17
17
|
*
|
|
18
18
|
* [ASSUMPTION] validateDefaultValueType _functionName Parameter
|
|
19
19
|
* - Parameter accepted but unused (prefixed with _ to satisfy eslint)
|
|
20
|
-
* - Kept for API consistency with
|
|
21
|
-
*
|
|
22
|
-
* [ASSUMPTION] validateHostFunctionArgs Args Array Mutation
|
|
23
|
-
* - args array mutated in-place when substituting default values
|
|
24
|
-
* - Per spec algorithm: "Apply default values for missing arguments before validation"
|
|
25
|
-
* - Mutation occurs before host function receives args, maintaining immutability contract
|
|
20
|
+
* - Kept for API consistency with validateCallableArgs signature
|
|
26
21
|
*/
|
|
27
|
-
import type { BodyNode,
|
|
28
|
-
|
|
29
|
-
import type {
|
|
22
|
+
import type { BodyNode, SourceLocation } from '../../types.js';
|
|
23
|
+
import type { RillMethod } from './types.js';
|
|
24
|
+
import type { RillType, RillTypeValue, RillValue } from './values.js';
|
|
30
25
|
interface RuntimeContextLike {
|
|
31
26
|
readonly parent?: RuntimeContextLike | undefined;
|
|
32
27
|
readonly variables: Map<string, RillValue>;
|
|
@@ -39,50 +34,52 @@ interface RuntimeContextLike {
|
|
|
39
34
|
*/
|
|
40
35
|
export type CallableFn = (args: RillValue[], ctx: RuntimeContextLike, location?: SourceLocation) => RillValue | Promise<RillValue>;
|
|
41
36
|
/**
|
|
42
|
-
*
|
|
37
|
+
* Unified parameter definition for all callable types (script closures and host functions).
|
|
43
38
|
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
39
|
+
* - type: undefined means the parameter accepts any type (any-typed).
|
|
40
|
+
* - defaultValue: undefined means the parameter is required.
|
|
41
|
+
* - annotations: evaluated key-value pairs; empty object ({}) when no annotations present.
|
|
42
|
+
* - Description lives at annotations.description — no separate description field.
|
|
46
43
|
*/
|
|
47
|
-
export interface
|
|
44
|
+
export interface RillParam {
|
|
48
45
|
readonly name: string;
|
|
49
|
-
readonly
|
|
50
|
-
readonly defaultValue: RillValue |
|
|
51
|
-
/** Evaluated parameter-level annotations (e.g., ^(cache: true)) */
|
|
46
|
+
readonly type: RillType | undefined;
|
|
47
|
+
readonly defaultValue: RillValue | undefined;
|
|
52
48
|
readonly annotations: Record<string, RillValue>;
|
|
53
|
-
/** Human-readable parameter description (optional, from host functions) */
|
|
54
|
-
readonly description?: string;
|
|
55
49
|
}
|
|
56
50
|
/**
|
|
57
|
-
*
|
|
51
|
+
* Unified host function definition using RillParam for parameter declarations.
|
|
58
52
|
*
|
|
59
|
-
*
|
|
60
|
-
*
|
|
53
|
+
* Replaces HostFunctionDefinition. Runtime does NOT validate return values
|
|
54
|
+
* against returnType at call time.
|
|
61
55
|
*/
|
|
62
|
-
export interface
|
|
63
|
-
|
|
64
|
-
readonly
|
|
65
|
-
/** Expected type: 6 primitive types plus 'any' */
|
|
66
|
-
readonly type: 'string' | 'number' | 'bool' | 'list' | 'dict' | 'vector' | 'any';
|
|
67
|
-
/** Default value if argument omitted. Makes parameter optional. */
|
|
68
|
-
readonly defaultValue?: RillValue;
|
|
69
|
-
/** Human-readable parameter description (optional) */
|
|
56
|
+
export interface RillFunction {
|
|
57
|
+
readonly params: readonly RillParam[];
|
|
58
|
+
readonly fn: CallableFn;
|
|
70
59
|
readonly description?: string;
|
|
60
|
+
readonly returnType?: RillType;
|
|
71
61
|
}
|
|
72
62
|
/**
|
|
73
|
-
*
|
|
74
|
-
*
|
|
75
|
-
* Runtime validates arguments before invocation.
|
|
63
|
+
* Base interface for all callable signatures.
|
|
64
|
+
* signature is an annotated rill closure type signature string.
|
|
76
65
|
*/
|
|
77
|
-
export interface
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
66
|
+
export interface RillCallableSignature {
|
|
67
|
+
readonly signature: string;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Signature for a host-provided function.
|
|
71
|
+
* Discriminated from RillFunction by presence of signature field.
|
|
72
|
+
*/
|
|
73
|
+
export interface RillFunctionSignature extends RillCallableSignature {
|
|
81
74
|
readonly fn: CallableFn;
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* Signature for a built-in method with receiver type constraints.
|
|
78
|
+
* receiverTypes contains valid RillTypeName strings (e.g., ["string", "list"]).
|
|
79
|
+
*/
|
|
80
|
+
export interface RillMethodSignature extends RillCallableSignature {
|
|
81
|
+
readonly method: RillMethod;
|
|
82
|
+
readonly receiverTypes: readonly string[];
|
|
86
83
|
}
|
|
87
84
|
/** Common fields for all callable types */
|
|
88
85
|
interface CallableBase {
|
|
@@ -104,7 +101,7 @@ interface CallableBase {
|
|
|
104
101
|
*/
|
|
105
102
|
export interface ScriptCallable extends CallableBase {
|
|
106
103
|
readonly kind: 'script';
|
|
107
|
-
readonly params:
|
|
104
|
+
readonly params: readonly RillParam[];
|
|
108
105
|
readonly body: BodyNode;
|
|
109
106
|
/** Reference to the scope where this closure was defined (late binding) */
|
|
110
107
|
readonly definingScope: RuntimeContextLike;
|
|
@@ -113,7 +110,7 @@ export interface ScriptCallable extends CallableBase {
|
|
|
113
110
|
/** Evaluated parameter annotations keyed by parameter name */
|
|
114
111
|
readonly paramAnnotations: Record<string, Record<string, RillValue>>;
|
|
115
112
|
/** Cached input structural type built from params at creation time — used by `$fn.^input` */
|
|
116
|
-
readonly inputShape:
|
|
113
|
+
readonly inputShape: RillType;
|
|
117
114
|
/** Return type target from `:type-target` syntax — set in Phase 2, undefined until then */
|
|
118
115
|
readonly returnShape?: RillTypeValue | undefined;
|
|
119
116
|
}
|
|
@@ -125,12 +122,14 @@ export interface RuntimeCallable extends CallableBase {
|
|
|
125
122
|
/** Application callable - host application-provided functions */
|
|
126
123
|
export interface ApplicationCallable extends CallableBase {
|
|
127
124
|
readonly kind: 'application';
|
|
128
|
-
readonly params:
|
|
125
|
+
readonly params: RillParam[] | undefined;
|
|
129
126
|
readonly fn: CallableFn;
|
|
130
127
|
/** Human-readable function description (optional, from host functions) */
|
|
131
128
|
readonly description?: string;
|
|
132
129
|
/** Return type declaration (optional, from host functions) */
|
|
133
|
-
readonly returnType?:
|
|
130
|
+
readonly returnType?: RillType | undefined;
|
|
131
|
+
/** Original signature string as provided by host (only set for RillFunctionSignature registrations) */
|
|
132
|
+
readonly originalSignature?: string | undefined;
|
|
134
133
|
}
|
|
135
134
|
/** Union of all callable types */
|
|
136
135
|
export type RillCallable = ScriptCallable | RuntimeCallable | ApplicationCallable;
|
|
@@ -166,19 +165,19 @@ export declare function formatCallable(callable: RillCallable): string;
|
|
|
166
165
|
*/
|
|
167
166
|
export declare function callableEquals(a: ScriptCallable, b: ScriptCallable, valueEquals?: (a: RillValue, b: RillValue) => boolean): boolean;
|
|
168
167
|
/**
|
|
169
|
-
* Build a
|
|
168
|
+
* Build a RillType closure variant from a closure's parameter list.
|
|
170
169
|
*
|
|
171
170
|
* Called at closure creation time to build the structural type for `$fn.^input`.
|
|
172
|
-
* - Typed params
|
|
173
|
-
* - Untyped params (
|
|
174
|
-
* - Return type is always {
|
|
171
|
+
* - Typed params use param.type directly when present
|
|
172
|
+
* - Untyped params (type: undefined) map to { type: 'any' }
|
|
173
|
+
* - Return type is always { type: 'any' }
|
|
175
174
|
*
|
|
176
175
|
* No validation: parser already validates type names.
|
|
177
176
|
*
|
|
178
|
-
* @param params - Closure parameter definitions
|
|
179
|
-
* @returns Frozen
|
|
177
|
+
* @param params - Closure parameter definitions (RillParam[])
|
|
178
|
+
* @returns Frozen RillType with closure variant
|
|
180
179
|
*/
|
|
181
|
-
export declare function paramsToStructuralType(params:
|
|
180
|
+
export declare function paramsToStructuralType(params: readonly RillParam[]): RillType;
|
|
182
181
|
/**
|
|
183
182
|
* Validate defaultValue type matches declared parameter type.
|
|
184
183
|
*
|
|
@@ -189,31 +188,21 @@ export declare function paramsToStructuralType(params: CallableParam[]): RillStr
|
|
|
189
188
|
* @param _functionName - Function name (unused, kept for API consistency)
|
|
190
189
|
* @throws Error if defaultValue type doesn't match param.type
|
|
191
190
|
*/
|
|
192
|
-
export declare function validateDefaultValueType(param:
|
|
193
|
-
/**
|
|
194
|
-
* Validate host function arguments against parameter declarations.
|
|
195
|
-
*
|
|
196
|
-
* Called before function invocation to enforce type contracts.
|
|
197
|
-
* Throws RuntimeError on validation failure.
|
|
198
|
-
*
|
|
199
|
-
* @param args - Evaluated arguments from call site
|
|
200
|
-
* @param params - Parameter declarations from function definition
|
|
201
|
-
* @param functionName - Function name for error messages
|
|
202
|
-
* @param location - Source location for error reporting
|
|
203
|
-
* @throws RuntimeError with RUNTIME_TYPE_ERROR on validation failure
|
|
204
|
-
*/
|
|
205
|
-
export declare function validateHostFunctionArgs(args: RillValue[], params: readonly HostFunctionParam[], functionName: string, location?: SourceLocation): void;
|
|
191
|
+
export declare function validateDefaultValueType(param: RillParam, _functionName: string): void;
|
|
206
192
|
/**
|
|
207
|
-
* Validate arguments against
|
|
193
|
+
* Validate arguments against RillParam[] using structural type matching.
|
|
208
194
|
*
|
|
209
|
-
*
|
|
210
|
-
*
|
|
195
|
+
* Single validation path for all callable kinds (host, built-in, script).
|
|
196
|
+
* Uses structuralTypeMatches for type checking when param.type is defined.
|
|
197
|
+
* Skips type check when param.type is undefined (any-typed).
|
|
198
|
+
* Applies defaultValue in-place on the args array before validation.
|
|
211
199
|
*
|
|
212
200
|
* @param args - Arguments array (mutated in-place when defaults applied)
|
|
213
201
|
* @param params - Parameter definitions
|
|
214
202
|
* @param functionName - Function name for error messages
|
|
215
203
|
* @param location - Source location for error reporting
|
|
216
|
-
* @throws RuntimeError with
|
|
204
|
+
* @throws RuntimeError with RILL-R001 on validation failure
|
|
217
205
|
*/
|
|
218
|
-
export declare function validateCallableArgs(args: RillValue[], params: readonly
|
|
206
|
+
export declare function validateCallableArgs(args: RillValue[], params: readonly RillParam[], functionName: string, location?: SourceLocation): void;
|
|
207
|
+
export {};
|
|
219
208
|
//# sourceMappingURL=callable.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callable.d.ts","sourceRoot":"","sources":["../../../src/runtime/core/callable.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"callable.d.ts","sourceRoot":"","sources":["../../../src/runtime/core/callable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAC/D,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAG7C,OAAO,KAAK,EAAE,QAAQ,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAYtE,UAAU,kBAAkB;IAC1B,QAAQ,CAAC,MAAM,CAAC,EAAE,kBAAkB,GAAG,SAAS,CAAC;IACjD,QAAQ,CAAC,SAAS,EAAE,GAAG,CAAC,MAAM,EAAE,SAAS,CAAC,CAAC;IAC3C,SAAS,EAAE,SAAS,CAAC;IACrB,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,SAAS,CAAC;CACxD;AAED;;;GAGG;AACH,MAAM,MAAM,UAAU,GAAG,CACvB,IAAI,EAAE,SAAS,EAAE,EACjB,GAAG,EAAE,kBAAkB,EACvB,QAAQ,CAAC,EAAE,cAAc,KACtB,SAAS,GAAG,OAAO,CAAC,SAAS,CAAC,CAAC;AAEpC;;;;;;;GAOG;AACH,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,QAAQ,GAAG,SAAS,CAAC;IACpC,QAAQ,CAAC,YAA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,eAAe,CAE5E;AAED,0CAA0C;AAC1C,wBAAgB,qBAAqB,CACnC,KAAK,EAAE,SAAS,GACf,KAAK,IAAI,mBAAmB,CAE9B;AAED;;;;;GAKG;AACH,wBAAgB,QAAQ,CACtB,EAAE,EAAE,UAAU,EACd,UAAU,UAAQ,GACjB,mBAAmB,CAQrB;AAED,6EAA6E;AAC7E,wBAAgB,MAAM,CAAC,KAAK,EAAE,SAAS,GAAG,KAAK,IAAI,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,CAQ3E;AAED,oCAAoC;AACpC,wBAAgB,cAAc,CAAC,QAAQ,EAAE,YAAY,GAAG,MAAM,CAM7D;AAwBD;;;;;;;;;;GAUG;AACH,wBAAgB,cAAc,CAC5B,CAAC,EAAE,cAAc,EACjB,CAAC,EAAE,cAAc,EACjB,WAAW,GAAE,CAAC,CAAC,EAAE,SAAS,EAAE,CAAC,EAAE,SAAS,KAAK,OACV,GAClC,OAAO,CAsDT;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,sBAAsB,CAAC,MAAM,EAAE,SAAS,SAAS,EAAE,GAAG,QAAQ,CAW7E;AAED;;;;;;;;;GASG;AACH,wBAAgB,wBAAwB,CACtC,KAAK,EAAE,SAAS,EAChB,aAAa,EAAE,MAAM,GACpB,IAAI,CAaN;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,SAAS,EAAE,EACjB,MAAM,EAAE,SAAS,SAAS,EAAE,EAC5B,YAAY,EAAE,MAAM,EACpB,QAAQ,CAAC,EAAE,cAAc,GACxB,IAAI,CA4DN"}
|
|
@@ -17,16 +17,11 @@
|
|
|
17
17
|
*
|
|
18
18
|
* [ASSUMPTION] validateDefaultValueType _functionName Parameter
|
|
19
19
|
* - Parameter accepted but unused (prefixed with _ to satisfy eslint)
|
|
20
|
-
* - Kept for API consistency with
|
|
21
|
-
*
|
|
22
|
-
* [ASSUMPTION] validateHostFunctionArgs Args Array Mutation
|
|
23
|
-
* - args array mutated in-place when substituting default values
|
|
24
|
-
* - Per spec algorithm: "Apply default values for missing arguments before validation"
|
|
25
|
-
* - Mutation occurs before host function receives args, maintaining immutability contract
|
|
20
|
+
* - Kept for API consistency with validateCallableArgs signature
|
|
26
21
|
*/
|
|
27
22
|
import { RuntimeError } from '../../types.js';
|
|
28
23
|
import { astEquals } from './equals.js';
|
|
29
|
-
import { formatValue, inferType, isTuple } from './values.js';
|
|
24
|
+
import { formatValue, formatStructuralType, inferType, isTuple, structuralTypeEquals, structuralTypeMatches, } from './values.js';
|
|
30
25
|
/** Type guard for any callable */
|
|
31
26
|
export function isCallable(value) {
|
|
32
27
|
return (typeof value === 'object' &&
|
|
@@ -116,7 +111,14 @@ export function callableEquals(a, b, valueEquals = (x, y) => formatValue(x) ===
|
|
|
116
111
|
return false;
|
|
117
112
|
if (ap.name !== bp.name)
|
|
118
113
|
return false;
|
|
119
|
-
|
|
114
|
+
// Compare type via structuralTypeEquals; absent type (any-typed) matches absent type
|
|
115
|
+
if (ap.type === undefined && bp.type !== undefined)
|
|
116
|
+
return false;
|
|
117
|
+
if (ap.type !== undefined && bp.type === undefined)
|
|
118
|
+
return false;
|
|
119
|
+
if (ap.type !== undefined &&
|
|
120
|
+
bp.type !== undefined &&
|
|
121
|
+
!structuralTypeEquals(ap.type, bp.type))
|
|
120
122
|
return false;
|
|
121
123
|
if (!valueEquals(ap.defaultValue ?? null, bp.defaultValue ?? null)) {
|
|
122
124
|
return false;
|
|
@@ -155,29 +157,27 @@ export function callableEquals(a, b, valueEquals = (x, y) => formatValue(x) ===
|
|
|
155
157
|
return true;
|
|
156
158
|
}
|
|
157
159
|
/**
|
|
158
|
-
* Build a
|
|
160
|
+
* Build a RillType closure variant from a closure's parameter list.
|
|
159
161
|
*
|
|
160
162
|
* Called at closure creation time to build the structural type for `$fn.^input`.
|
|
161
|
-
* - Typed params
|
|
162
|
-
* - Untyped params (
|
|
163
|
-
* - Return type is always {
|
|
163
|
+
* - Typed params use param.type directly when present
|
|
164
|
+
* - Untyped params (type: undefined) map to { type: 'any' }
|
|
165
|
+
* - Return type is always { type: 'any' }
|
|
164
166
|
*
|
|
165
167
|
* No validation: parser already validates type names.
|
|
166
168
|
*
|
|
167
|
-
* @param params - Closure parameter definitions
|
|
168
|
-
* @returns Frozen
|
|
169
|
+
* @param params - Closure parameter definitions (RillParam[])
|
|
170
|
+
* @returns Frozen RillType with closure variant
|
|
169
171
|
*/
|
|
170
172
|
export function paramsToStructuralType(params) {
|
|
171
173
|
const closureParams = params.map((param) => {
|
|
172
|
-
const paramType = param.
|
|
173
|
-
? { kind: 'primitive', name: param.typeName }
|
|
174
|
-
: { kind: 'any' };
|
|
174
|
+
const paramType = param.type ?? { type: 'any' };
|
|
175
175
|
return [param.name, paramType];
|
|
176
176
|
});
|
|
177
177
|
return Object.freeze({
|
|
178
|
-
|
|
178
|
+
type: 'closure',
|
|
179
179
|
params: closureParams,
|
|
180
|
-
ret: {
|
|
180
|
+
ret: { type: 'any' },
|
|
181
181
|
});
|
|
182
182
|
}
|
|
183
183
|
/**
|
|
@@ -193,83 +193,28 @@ export function paramsToStructuralType(params) {
|
|
|
193
193
|
export function validateDefaultValueType(param, _functionName) {
|
|
194
194
|
if (param.defaultValue === undefined)
|
|
195
195
|
return;
|
|
196
|
-
// Skip validation
|
|
197
|
-
if (param.type ===
|
|
196
|
+
// Skip validation when type is undefined (any-typed, all defaults valid)
|
|
197
|
+
if (param.type === undefined)
|
|
198
198
|
return;
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
199
|
+
if (!structuralTypeMatches(param.defaultValue, param.type)) {
|
|
200
|
+
const actualType = inferType(param.defaultValue);
|
|
201
|
+
const expectedType = formatStructuralType(param.type);
|
|
202
202
|
throw new Error(`Invalid defaultValue for parameter '${param.name}': expected ${expectedType}, got ${actualType}`);
|
|
203
203
|
}
|
|
204
204
|
}
|
|
205
205
|
/**
|
|
206
|
-
* Validate
|
|
206
|
+
* Validate arguments against RillParam[] using structural type matching.
|
|
207
207
|
*
|
|
208
|
-
*
|
|
209
|
-
*
|
|
210
|
-
*
|
|
211
|
-
*
|
|
212
|
-
* @param params - Parameter declarations from function definition
|
|
213
|
-
* @param functionName - Function name for error messages
|
|
214
|
-
* @param location - Source location for error reporting
|
|
215
|
-
* @throws RuntimeError with RUNTIME_TYPE_ERROR on validation failure
|
|
216
|
-
*/
|
|
217
|
-
export function validateHostFunctionArgs(args, params, functionName, location) {
|
|
218
|
-
// Check for excess arguments
|
|
219
|
-
if (args.length > params.length) {
|
|
220
|
-
throw new RuntimeError('RILL-R001', `Function '${functionName}' expects ${params.length} arguments, got ${args.length}`, location, {
|
|
221
|
-
functionName,
|
|
222
|
-
expectedCount: params.length,
|
|
223
|
-
actualCount: args.length,
|
|
224
|
-
});
|
|
225
|
-
}
|
|
226
|
-
// Validate each parameter
|
|
227
|
-
for (let i = 0; i < params.length; i++) {
|
|
228
|
-
const param = params[i];
|
|
229
|
-
if (param === undefined)
|
|
230
|
-
continue;
|
|
231
|
-
let arg = args[i];
|
|
232
|
-
// Handle missing argument
|
|
233
|
-
if (arg === undefined) {
|
|
234
|
-
if (param.defaultValue !== undefined) {
|
|
235
|
-
// Substitute default value (already validated at registration)
|
|
236
|
-
arg = param.defaultValue;
|
|
237
|
-
args[i] = arg;
|
|
238
|
-
}
|
|
239
|
-
else {
|
|
240
|
-
// Missing required argument
|
|
241
|
-
throw new RuntimeError('RILL-R001', `Missing required argument '${param.name}' for function '${functionName}'`, location, {
|
|
242
|
-
functionName,
|
|
243
|
-
paramName: param.name,
|
|
244
|
-
});
|
|
245
|
-
}
|
|
246
|
-
}
|
|
247
|
-
// Validate argument type (skip for 'any' type)
|
|
248
|
-
if (param.type !== 'any') {
|
|
249
|
-
const actualType = inferType(arg);
|
|
250
|
-
const expectedType = param.type;
|
|
251
|
-
if (actualType !== expectedType) {
|
|
252
|
-
throw new RuntimeError('RILL-R001', `Type mismatch in ${functionName}: parameter '${param.name}' expects ${expectedType}, got ${actualType}`, location, {
|
|
253
|
-
functionName,
|
|
254
|
-
paramName: param.name,
|
|
255
|
-
expectedType,
|
|
256
|
-
actualType,
|
|
257
|
-
});
|
|
258
|
-
}
|
|
259
|
-
}
|
|
260
|
-
}
|
|
261
|
-
}
|
|
262
|
-
/**
|
|
263
|
-
* Validate arguments against CallableParam[] for ApplicationCallable.
|
|
264
|
-
*
|
|
265
|
-
* Similar to validateHostFunctionArgs but works with CallableParam[] (used in ApplicationCallable).
|
|
266
|
-
* Validates argument count, applies defaults, and checks types for primitive parameters.
|
|
208
|
+
* Single validation path for all callable kinds (host, built-in, script).
|
|
209
|
+
* Uses structuralTypeMatches for type checking when param.type is defined.
|
|
210
|
+
* Skips type check when param.type is undefined (any-typed).
|
|
211
|
+
* Applies defaultValue in-place on the args array before validation.
|
|
267
212
|
*
|
|
268
213
|
* @param args - Arguments array (mutated in-place when defaults applied)
|
|
269
214
|
* @param params - Parameter definitions
|
|
270
215
|
* @param functionName - Function name for error messages
|
|
271
216
|
* @param location - Source location for error reporting
|
|
272
|
-
* @throws RuntimeError with
|
|
217
|
+
* @throws RuntimeError with RILL-R001 on validation failure
|
|
273
218
|
*/
|
|
274
219
|
export function validateCallableArgs(args, params, functionName, location) {
|
|
275
220
|
// Check for excess arguments
|
|
@@ -286,10 +231,9 @@ export function validateCallableArgs(args, params, functionName, location) {
|
|
|
286
231
|
if (param === undefined)
|
|
287
232
|
continue;
|
|
288
233
|
let arg = args[i];
|
|
289
|
-
//
|
|
234
|
+
// Apply defaultValue in-place for missing arguments
|
|
290
235
|
if (arg === undefined) {
|
|
291
|
-
if (param.defaultValue !==
|
|
292
|
-
// Substitute default value
|
|
236
|
+
if (param.defaultValue !== undefined) {
|
|
293
237
|
arg = param.defaultValue;
|
|
294
238
|
args[i] = arg;
|
|
295
239
|
}
|
|
@@ -301,11 +245,11 @@ export function validateCallableArgs(args, params, functionName, location) {
|
|
|
301
245
|
});
|
|
302
246
|
}
|
|
303
247
|
}
|
|
304
|
-
//
|
|
305
|
-
if (param.
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
248
|
+
// Type check via structuralTypeMatches when param.type is defined
|
|
249
|
+
if (param.type !== undefined) {
|
|
250
|
+
if (!structuralTypeMatches(arg, param.type)) {
|
|
251
|
+
const expectedType = formatStructuralType(param.type);
|
|
252
|
+
const actualType = inferType(arg);
|
|
309
253
|
throw new RuntimeError('RILL-R001', `Type mismatch in ${functionName}: parameter '${param.name}' expects ${expectedType}, got ${actualType}`, location, {
|
|
310
254
|
functionName,
|
|
311
255
|
paramName: param.name,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callable.js","sourceRoot":"","sources":["../../../src/runtime/core/callable.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"callable.js","sourceRoot":"","sources":["../../../src/runtime/core/callable.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAIH,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,OAAO,EACL,WAAW,EACX,oBAAoB,EACpB,SAAS,EACT,OAAO,EACP,oBAAoB,EACpB,qBAAqB,GACtB,MAAM,aAAa,CAAC;AAsIrB,kCAAkC;AAClC,MAAM,UAAU,UAAU,CAAC,KAAgB;IACzC,OAAO,CACL,OAAO,KAAK,KAAK,QAAQ;QACzB,KAAK,KAAK,IAAI;QACd,QAAQ,IAAI,KAAK;QACjB,KAAK,CAAC,MAAM,KAAK,UAAU,CAC5B,CAAC;AACJ,CAAC;AAED,qCAAqC;AACrC,MAAM,UAAU,gBAAgB,CAAC,KAAgB;IAC/C,OAAO,UAAU,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,IAAI,KAAK,QAAQ,CAAC;AACtD,CAAC;AAED,sCAAsC;AACtC,MAAM,UAAU,iBAAiB,CAAC,KAAgB;IAChD,OAAO,UAAU,CAAC,KAAK,CAAC,I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,mBAAmB,YAAY,GAAG,EAC1E,QAAQ,EACR;oBACE,YAAY;oBACZ,SAAS,EAAE,KAAK,CAAC,IAAI;iBACtB,CACF,CAAC;YACJ,CAAC;QACH,CAAC;QAED,kEAAkE;QAClE,IAAI,KAAK,CAAC,IAAI,KAAK,SAAS,EAAE,CAAC;YAC7B,IAAI,CAAC,qBAAqB,CAAC,GAAG,EAAE,KAAK,CAAC,IAAI,CAAC,EAAE,CAAC;gBAC5C,MAAM,YAAY,GAAG,oBAAoB,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;gBACtD,MAAM,UAAU,GAAG,SAAS,CAAC,GAAG,CAAC,CAAC;gBAClC,MAAM,IAAI,YAAY,CACpB,WAAW,EACX,oBAAoB,YAAY,gBAAgB,KAAK,CAAC,IAAI,aAAa,YAAY,SAAS,UAAU,EAAE,EACxG,QAAQ,EACR;oBACE,YAAY;oBACZ,SAAS,EAAE,KAAK,CAAC,IAAI;oBACrB,YAAY;oBACZ,UAAU;iBACX,CACF,CAAC;YACJ,CAAC;QACH,CAAC;IACH,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/runtime/core/context.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;
|
|
1
|
+
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../../src/runtime/core/context.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAKH,OAAO,KAAK,EAGV,cAAc,EACd,cAAc,EAEf,MAAM,YAAY,CAAC;AAEpB,OAAO,EAAa,KAAK,SAAS,EAAE,MAAM,aAAa,CAAC;AAqExD;;;GAGG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,GAAE,cAAmB,GAC3B,cAAc,CAoKhB;AAED;;;;GAIG;AACH,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,cAAc,GAAG,cAAc,CA4BzE;AAED;;;GAGG;AACH,wBAAgB,WAAW,CACzB,GAAG,EAAE,cAAc,EACnB,IAAI,EAAE,MAAM,GACX,SAAS,GAAG,SAAS,CAQvB;AAED;;GAEG;AACH,wBAAgB,WAAW,CAAC,GAAG,EAAE,cAAc,EAAE,IAAI,EAAE,MAAM,GAAG,OAAO,CAQtE;AAED;;;;;;;GAOG;AACH,wBAAgB,YAAY,CAC1B,KAAK,EAAE,OAAO,gBAAgB,EAAE,SAAS,GACxC,SAAS,OAAO,gBAAgB,EAAE,SAAS,EAAE,CAkB/C;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAC3B,GAAG,EAAE,cAAc,EACnB,KAAK,EAAE,OAAO,gBAAgB,EAAE,SAAS,GACxC,IAAI,CAON;AAED;;GAEG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,cAAc,GAAG,IAAI,CAKtD"}
|