@powerlines/deepkit 0.7.3 → 0.7.4

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.
@@ -1113,4 +1113,5 @@ pathJoin.__type = [
1113
1113
  ];
1114
1114
 
1115
1115
  //#endregion
1116
- export { AsyncEventEmitter, AsyncFunction, CompilerContext, CustomError, EmitterEvent, EventEmitter, Mutex, ParsedHost, ProcessLock, ProcessLocker, Timer, __ΩAbstractClassType, __ΩAsyncEventSubscription, __ΩClassType, __ΩCustomError, __ΩEventSubscription, __ΩExtractClassType, __ΩInject, __ΩInjectMeta, __ΩTypeAnnotation, appendObject, applyDefaults, arrayClear, arrayHasItem, arrayMoveItem, arrayRemoveItem, assertDefined, assertInstanceOf, asyncOperation, average, base64ToUint8Array, bufferConcat, bufferToString, bufferedGate, capitalize, changeClass, clearTick, collectForMicrotask, copy, createBuffer, createDynamicClass, createStack, deletePathValue, each, eachKey, eachPair, empty, ensureError, escapeRegExp, extractMethodBody, extractParameters, first, firstKey, fixAsyncOperation, formatError, forwardTypeArguments, getClassName, getClassPropertyName, getClassTypeFromInstance, getCurrentFileName, getEnumKeyLabelMap, getEnumLabel, getEnumLabels, getEnumValues, getInheritanceChain, getObjectKeysSize, getParentClass, getPathValue, getValidEnumValue, hasProperty, humanBytes, identifyType, inDebugMode, indent, indexOf, isArray, isAsyncFunction, isClass, isClassInstance, isConstructable, isFunction, isGlobalClass, isInteger, isIterable, isNull, isNumber, isNumeric, isObject, isObjectLiteral, isPlainObject, isPromise, isPrototypeOfBase, isSet, isString, isUndefined, isValidEnumValue, iterableSize, last, lastKey, log, mergePromiseStack, mergeStack, nativeBase64ToUint8Array, nextTick, parseHost, pathBasename, pathDirectory, pathExtension, pathJoin, pathNormalize, prependObjectKeys, prettyPrintObject, range, rangeArray, removeStrings, setPathValue, singleStack, size, sleep, stack, stringifyValueWithType, throttleTime, time, toFastProperties, uint8ArrayToUtf8, urlJoin, zip };
1116
+ export { AsyncEventEmitter, AsyncFunction, CompilerContext, CustomError, EmitterEvent, EventEmitter, Mutex, ParsedHost, ProcessLock, ProcessLocker, Timer, __ΩAbstractClassType, __ΩAsyncEventSubscription, __ΩClassType, __ΩCustomError, __ΩEventSubscription, __ΩExtractClassType, __ΩInject, __ΩInjectMeta, __ΩTypeAnnotation, appendObject, applyDefaults, arrayClear, arrayHasItem, arrayMoveItem, arrayRemoveItem, assertDefined, assertInstanceOf, asyncOperation, average, base64ToUint8Array, bufferConcat, bufferToString, bufferedGate, capitalize, changeClass, clearTick, collectForMicrotask, copy, createBuffer, createDynamicClass, createStack, deletePathValue, each, eachKey, eachPair, empty, ensureError, escapeRegExp, extractMethodBody, extractParameters, first, firstKey, fixAsyncOperation, formatError, forwardTypeArguments, getClassName, getClassPropertyName, getClassTypeFromInstance, getCurrentFileName, getEnumKeyLabelMap, getEnumLabel, getEnumLabels, getEnumValues, getInheritanceChain, getObjectKeysSize, getParentClass, getPathValue, getValidEnumValue, hasProperty, humanBytes, identifyType, inDebugMode, indent, indexOf, isArray, isAsyncFunction, isClass, isClassInstance, isConstructable, isFunction, isGlobalClass, isInteger, isIterable, isNull, isNumber, isNumeric, isObject, isObjectLiteral, isPlainObject, isPromise, isPrototypeOfBase, isSet, isString, isUndefined, isValidEnumValue, iterableSize, last, lastKey, log, mergePromiseStack, mergeStack, nativeBase64ToUint8Array, nextTick, parseHost, pathBasename, pathDirectory, pathExtension, pathJoin, pathNormalize, prependObjectKeys, prettyPrintObject, range, rangeArray, removeStrings, setPathValue, singleStack, size, sleep, stack, stringifyValueWithType, throttleTime, time, toFastProperties, uint8ArrayToUtf8, urlJoin, zip };
1117
+ //# sourceMappingURL=core.mjs.map
@@ -2464,4 +2464,5 @@ capitalize.__type = [
2464
2464
  ];
2465
2465
 
2466
2466
  //#endregion
2467
- export { isFunction as $, first as A, eachKey as At, getObjectKeysSize as B, copy as C, setPathValue as Ct, empty as D, time as Dt, deletePathValue as E, stringifyValueWithType as Et, getClassName as F, identifyType as G, getPathValue as H, getClassPropertyName as I, isArray as J, inDebugMode as K, getClassTypeFromInstance as L, fixAsyncOperation as M, formatError as N, ensureError as O, zip as Ot, forwardTypeArguments as P, isConstructable as Q, getCurrentFileName as R, collectForMicrotask as S, rangeArray as St, createStack as T, sleep as Tt, hasProperty as U, getParentClass as V, humanBytes as W, isClass as X, isAsyncFunction as Y, isClassInstance as Z, assertDefined as _, mergePromiseStack as _t, arrayHasItem as a, isNumeric as at, average as b, prettyPrintObject as bt, toFastProperties as c, isPlainObject as ct, __ΩAbstractClassType as d, isSet as dt, isGlobalClass as et, __ΩClassType as f, isString as ft, applyDefaults as g, lastKey as gt, appendObject as h, last as ht, arrayClear as i, isNumber as it, firstKey as j, eachPair as jt, escapeRegExp as k, each as kt, AsyncFunction as l, isPromise as lt, __ΩExtractClassType as m, iterableSize as mt, indent as n, isIterable as nt, arrayMoveItem as o, isObject as ot, __ΩCustomError as p, isUndefined as pt, indexOf as q, CompilerContext as r, isNull as rt, arrayRemoveItem as s, isObjectLiteral as st, capitalize as t, isInteger as tt, CustomError as u, isPrototypeOfBase as ut, assertInstanceOf as v, mergeStack as vt, createDynamicClass as w, size as wt, changeClass as x, range as xt, asyncOperation as y, prependObjectKeys as yt, getInheritanceChain as z };
2467
+ export { isFunction as $, first as A, eachKey as At, getObjectKeysSize as B, copy as C, setPathValue as Ct, empty as D, time as Dt, deletePathValue as E, stringifyValueWithType as Et, getClassName as F, identifyType as G, getPathValue as H, getClassPropertyName as I, isArray as J, inDebugMode as K, getClassTypeFromInstance as L, fixAsyncOperation as M, formatError as N, ensureError as O, zip as Ot, forwardTypeArguments as P, isConstructable as Q, getCurrentFileName as R, collectForMicrotask as S, rangeArray as St, createStack as T, sleep as Tt, hasProperty as U, getParentClass as V, humanBytes as W, isClass as X, isAsyncFunction as Y, isClassInstance as Z, assertDefined as _, mergePromiseStack as _t, arrayHasItem as a, isNumeric as at, average as b, prettyPrintObject as bt, toFastProperties as c, isPlainObject as ct, __ΩAbstractClassType as d, isSet as dt, isGlobalClass as et, __ΩClassType as f, isString as ft, applyDefaults as g, lastKey as gt, appendObject as h, last as ht, arrayClear as i, isNumber as it, firstKey as j, eachPair as jt, escapeRegExp as k, each as kt, AsyncFunction as l, isPromise as lt, __ΩExtractClassType as m, iterableSize as mt, indent as n, isIterable as nt, arrayMoveItem as o, isObject as ot, __ΩCustomError as p, isUndefined as pt, indexOf as q, CompilerContext as r, isNull as rt, arrayRemoveItem as s, isObjectLiteral as st, capitalize as t, isInteger as tt, CustomError as u, isPrototypeOfBase as ut, assertInstanceOf as v, mergeStack as vt, createDynamicClass as w, size as wt, changeClass as x, range as xt, asyncOperation as y, prependObjectKeys as yt, getInheritanceChain as z };
2468
+ //# sourceMappingURL=string-BuMgdahD.mjs.map
@@ -0,0 +1,223 @@
1
+ //#region ../../node_modules/.pnpm/@deepkit+type-spec@1.0.1_patch_hash=f3c3a4fd486751022d78f17d39a5a79f493bca20b185964ca1aba41fbfc93244/node_modules/@deepkit/type-spec/dist/cjs/src/type.d.ts
2
+ declare const enum MappedModifier {
3
+ optional = 1,
4
+ removeOptional = 2,
5
+ readonly = 4,
6
+ removeReadonly = 8
7
+ }
8
+ /**
9
+ * note: Checks are based on range checks (>, <, etc), so when adding
10
+ * new types a check is required for all code using `TypeNumberBrand`.
11
+ */
12
+ declare enum TypeNumberBrand {
13
+ integer = 0,
14
+ int8 = 1,
15
+ int16 = 2,
16
+ int32 = 3,
17
+ uint8 = 4,
18
+ uint16 = 5,
19
+ uint32 = 6,
20
+ float = 7,
21
+ float32 = 8,
22
+ float64 = 9
23
+ }
24
+ /**
25
+ * The instruction set.
26
+ * Should not be greater than 93 members, because we encode it via charCode starting at 33. +93 means we end up with charCode=126
27
+ * (which is '~' and the last char that can be represented without \x. The next 127 is '\x7F').
28
+ */
29
+ declare enum ReflectionOp {
30
+ never = 0,
31
+ any = 1,
32
+ unknown = 2,
33
+ void = 3,
34
+ object = 4,
35
+ string = 5,
36
+ number = 6,
37
+ numberBrand = 7,
38
+ boolean = 8,
39
+ bigint = 9,
40
+ symbol = 10,
41
+ null = 11,
42
+ undefined = 12,
43
+ /**
44
+ * The literal type of string, number, or boolean.
45
+ *
46
+ * This OP has 1 parameter. The next byte is the absolute address of the literal on the stack, which is the actual literal value.
47
+ *
48
+ * Pushes a function type.
49
+ */
50
+ literal = 13,
51
+ /**
52
+ * This OP pops all types on the current stack frame.
53
+ *
54
+ * This OP has 1 parameter. The next byte is the absolute address of a string|number|symbol entry on the stack.
55
+ *
56
+ * Pushes a function type.
57
+ */
58
+ function = 14,
59
+ /**
60
+ * This OP pops all types on the current stack frame.
61
+ *
62
+ * Pushes a method type.
63
+ */
64
+ method = 15,
65
+ methodSignature = 16,
66
+ //has 1 parameter, reference to stack for its property name
67
+ parameter = 17,
68
+ /**
69
+ * This OP pops the latest type entry on the stack.
70
+ *
71
+ * Pushes a property type.
72
+ */
73
+ property = 18,
74
+ propertySignature = 19,
75
+ //has 1 parameter, reference to stack for its property name
76
+ /**
77
+ * This OP pops all types on the current stack frame. Those types should be method|property.
78
+ *
79
+ * Pushes a TypeClass onto the stack.
80
+ */
81
+ class = 20,
82
+ /**
83
+ * If a class extends another class with generics, this OP represents the generic type arguments of the super class.
84
+ *
85
+ * e.g. `class A extends B<string, boolean>`, string and boolean are on the stack and classExtends pops() them, and then assigns to A.extendsTypeArguments = [string, boolean].
86
+ *
87
+ * This is only emitted when the class that is currently being described actually extends another class and uses generics.
88
+ *
89
+ * This OP has 1 argument and pops x types from the stack. X is the first argument.
90
+ * Expects a TypeClass on the stack.
91
+ */
92
+ classExtends = 21,
93
+ /**
94
+ * This OP has 1 parameter, the stack entry to the actual class symbol.
95
+ */
96
+ classReference = 22,
97
+ /**
98
+ * Marks the last entry in the stack as optional. Used for method|property. Equal to the QuestionMark operator in a property assignment.
99
+ */
100
+ optional = 23,
101
+ readonly = 24,
102
+ public = 25,
103
+ private = 26,
104
+ protected = 27,
105
+ abstract = 28,
106
+ defaultValue = 29,
107
+ description = 30,
108
+ rest = 31,
109
+ regexp = 32,
110
+ enum = 33,
111
+ enumMember = 34,
112
+ //has one argument, the name.
113
+ set = 35,
114
+ map = 36,
115
+ /**
116
+ * Pops the latest stack entry and uses it as T for an array type.
117
+ *
118
+ * Pushes an array type.
119
+ */
120
+ array = 37,
121
+ tuple = 38,
122
+ tupleMember = 39,
123
+ namedTupleMember = 40,
124
+ //has one argument, the name.
125
+ union = 41,
126
+ //pops frame. requires frame start when stack can be dirty.
127
+ intersection = 42,
128
+ indexSignature = 43,
129
+ objectLiteral = 44,
130
+ mappedType = 45,
131
+ //2 parameters: functionPointer and modifier.
132
+ in = 46,
133
+ frame = 47,
134
+ //creates a new stack frame
135
+ moveFrame = 48,
136
+ //pop() as T, pops the current stack frame, push(T)
137
+ return = 49,
138
+ templateLiteral = 50,
139
+ date = 51,
140
+ int8Array = 52,
141
+ uint8ClampedArray = 53,
142
+ uint8Array = 54,
143
+ int16Array = 55,
144
+ uint16Array = 56,
145
+ int32Array = 57,
146
+ uint32Array = 58,
147
+ float32Array = 59,
148
+ float64Array = 60,
149
+ bigInt64Array = 61,
150
+ arrayBuffer = 62,
151
+ promise = 63,
152
+ arg = 64,
153
+ //@deprecated. parameter is a number referencing an entry in the stack, relative to the beginning of the current frame, *-1. pushes that entry onto the stack. this is related to the calling convention.
154
+ typeParameter = 65,
155
+ //generic type parameter, e.g. T in a generic. has 1 parameter: reference to the name.
156
+ typeParameterDefault = 66,
157
+ //generic type parameter with a default value, e.g. T in a generic. has 1 parameter: reference to the name. pop() for the default value
158
+ var = 67,
159
+ //reserve a new variable in the stack
160
+ loads = 68,
161
+ //pushes to the stack a referenced value in the stack. has 2 parameters: <frame> <index>, frame is a negative offset to the frame, and index the index of the stack entry withing the referenced frame
162
+ indexAccess = 69,
163
+ //T['string'], 2 items on the stack
164
+ keyof = 70,
165
+ //keyof operator
166
+ infer = 71,
167
+ //2 params, like `loads`
168
+ typeof = 72,
169
+ //1 parameter that points to a function returning the runtime value from which we need to extract the type
170
+ condition = 73,
171
+ jumpCondition = 74,
172
+ //@deprecated. used when INFER is used in `extends` conditional branch. 2 args: left program, right program
173
+ jump = 75,
174
+ //jump to an address
175
+ call = 76,
176
+ //has one parameter, the next program address. creates a new stack frame with current program address as first stack entry, and jumps back to that + 1.
177
+ inline = 77,
178
+ inlineCall = 78,
179
+ distribute = 79,
180
+ //has one parameter, the co-routine program index.
181
+ extends = 80,
182
+ //X extends Y in a conditional type, XY popped from the stack, pushes boolean on the stack
183
+ widen = 81,
184
+ //widens the type on the stack, .e.g 'asd' => string, 34 => number, etc. this is necessary for infer runtime data, and widen if necessary (object member or non-contained literal)
185
+ static = 82,
186
+ mappedType2 = 83,
187
+ //same as mappedType2 but the given functionPointer returns a tuple [type, name]
188
+ functionReference = 84,
189
+ //Same as classReference but for functions
190
+ callSignature = 85,
191
+ //Same as function but for call signatures (in object literals)
192
+ /**
193
+ * Assign for Enum, Interface, Class, and TypeAlias declaration at the very end
194
+ * of the program the typeName. This is so that we have type names available even
195
+ * if the JS code is minified.
196
+ *
197
+ * his operator also assigns originTypes to the type, as it acts as the finalization
198
+ * step of a type.
199
+ */
200
+ typeName = 86,
201
+ //has one parameter, the index of the stack entry that contains the type name. Uses current head of the stack as type and assigns typeName to it.
202
+ /**
203
+ * If a class implement an interface or type,
204
+ *
205
+ * e.g. `class A implements B`, then B is on the stack and implements pops() it, and then assigns to A.implements = [B].
206
+ *
207
+ * This is only emitted when the class that is currently being described actually implements something.
208
+ *
209
+ * This OP has 1 argument and pops x types from the stack. X is the first argument.
210
+ * Expects a TypeClass on the stack.
211
+ */
212
+ implements = 87,
213
+ //pops one type from the stack and assigns it to the latest class on the stack as `implements` type.
214
+ nominal = 88,
215
+ //marks the last type on the stack as nominal. (used at the end of class/interface/type alias programs).
216
+ /**
217
+ * Custom Storm Software operators
218
+ */
219
+ tags = 89
220
+ }
221
+ //#endregion
222
+ export { ReflectionOp as n, TypeNumberBrand as r, MappedModifier as t };
223
+ //# sourceMappingURL=type-2yMJb9Mw.d.cts.map
@@ -0,0 +1,223 @@
1
+ //#region ../../node_modules/.pnpm/@deepkit+type-spec@1.0.1_patch_hash=f3c3a4fd486751022d78f17d39a5a79f493bca20b185964ca1aba41fbfc93244/node_modules/@deepkit/type-spec/dist/cjs/src/type.d.ts
2
+ declare const enum MappedModifier {
3
+ optional = 1,
4
+ removeOptional = 2,
5
+ readonly = 4,
6
+ removeReadonly = 8
7
+ }
8
+ /**
9
+ * note: Checks are based on range checks (>, <, etc), so when adding
10
+ * new types a check is required for all code using `TypeNumberBrand`.
11
+ */
12
+ declare enum TypeNumberBrand {
13
+ integer = 0,
14
+ int8 = 1,
15
+ int16 = 2,
16
+ int32 = 3,
17
+ uint8 = 4,
18
+ uint16 = 5,
19
+ uint32 = 6,
20
+ float = 7,
21
+ float32 = 8,
22
+ float64 = 9
23
+ }
24
+ /**
25
+ * The instruction set.
26
+ * Should not be greater than 93 members, because we encode it via charCode starting at 33. +93 means we end up with charCode=126
27
+ * (which is '~' and the last char that can be represented without \x. The next 127 is '\x7F').
28
+ */
29
+ declare enum ReflectionOp {
30
+ never = 0,
31
+ any = 1,
32
+ unknown = 2,
33
+ void = 3,
34
+ object = 4,
35
+ string = 5,
36
+ number = 6,
37
+ numberBrand = 7,
38
+ boolean = 8,
39
+ bigint = 9,
40
+ symbol = 10,
41
+ null = 11,
42
+ undefined = 12,
43
+ /**
44
+ * The literal type of string, number, or boolean.
45
+ *
46
+ * This OP has 1 parameter. The next byte is the absolute address of the literal on the stack, which is the actual literal value.
47
+ *
48
+ * Pushes a function type.
49
+ */
50
+ literal = 13,
51
+ /**
52
+ * This OP pops all types on the current stack frame.
53
+ *
54
+ * This OP has 1 parameter. The next byte is the absolute address of a string|number|symbol entry on the stack.
55
+ *
56
+ * Pushes a function type.
57
+ */
58
+ function = 14,
59
+ /**
60
+ * This OP pops all types on the current stack frame.
61
+ *
62
+ * Pushes a method type.
63
+ */
64
+ method = 15,
65
+ methodSignature = 16,
66
+ //has 1 parameter, reference to stack for its property name
67
+ parameter = 17,
68
+ /**
69
+ * This OP pops the latest type entry on the stack.
70
+ *
71
+ * Pushes a property type.
72
+ */
73
+ property = 18,
74
+ propertySignature = 19,
75
+ //has 1 parameter, reference to stack for its property name
76
+ /**
77
+ * This OP pops all types on the current stack frame. Those types should be method|property.
78
+ *
79
+ * Pushes a TypeClass onto the stack.
80
+ */
81
+ class = 20,
82
+ /**
83
+ * If a class extends another class with generics, this OP represents the generic type arguments of the super class.
84
+ *
85
+ * e.g. `class A extends B<string, boolean>`, string and boolean are on the stack and classExtends pops() them, and then assigns to A.extendsTypeArguments = [string, boolean].
86
+ *
87
+ * This is only emitted when the class that is currently being described actually extends another class and uses generics.
88
+ *
89
+ * This OP has 1 argument and pops x types from the stack. X is the first argument.
90
+ * Expects a TypeClass on the stack.
91
+ */
92
+ classExtends = 21,
93
+ /**
94
+ * This OP has 1 parameter, the stack entry to the actual class symbol.
95
+ */
96
+ classReference = 22,
97
+ /**
98
+ * Marks the last entry in the stack as optional. Used for method|property. Equal to the QuestionMark operator in a property assignment.
99
+ */
100
+ optional = 23,
101
+ readonly = 24,
102
+ public = 25,
103
+ private = 26,
104
+ protected = 27,
105
+ abstract = 28,
106
+ defaultValue = 29,
107
+ description = 30,
108
+ rest = 31,
109
+ regexp = 32,
110
+ enum = 33,
111
+ enumMember = 34,
112
+ //has one argument, the name.
113
+ set = 35,
114
+ map = 36,
115
+ /**
116
+ * Pops the latest stack entry and uses it as T for an array type.
117
+ *
118
+ * Pushes an array type.
119
+ */
120
+ array = 37,
121
+ tuple = 38,
122
+ tupleMember = 39,
123
+ namedTupleMember = 40,
124
+ //has one argument, the name.
125
+ union = 41,
126
+ //pops frame. requires frame start when stack can be dirty.
127
+ intersection = 42,
128
+ indexSignature = 43,
129
+ objectLiteral = 44,
130
+ mappedType = 45,
131
+ //2 parameters: functionPointer and modifier.
132
+ in = 46,
133
+ frame = 47,
134
+ //creates a new stack frame
135
+ moveFrame = 48,
136
+ //pop() as T, pops the current stack frame, push(T)
137
+ return = 49,
138
+ templateLiteral = 50,
139
+ date = 51,
140
+ int8Array = 52,
141
+ uint8ClampedArray = 53,
142
+ uint8Array = 54,
143
+ int16Array = 55,
144
+ uint16Array = 56,
145
+ int32Array = 57,
146
+ uint32Array = 58,
147
+ float32Array = 59,
148
+ float64Array = 60,
149
+ bigInt64Array = 61,
150
+ arrayBuffer = 62,
151
+ promise = 63,
152
+ arg = 64,
153
+ //@deprecated. parameter is a number referencing an entry in the stack, relative to the beginning of the current frame, *-1. pushes that entry onto the stack. this is related to the calling convention.
154
+ typeParameter = 65,
155
+ //generic type parameter, e.g. T in a generic. has 1 parameter: reference to the name.
156
+ typeParameterDefault = 66,
157
+ //generic type parameter with a default value, e.g. T in a generic. has 1 parameter: reference to the name. pop() for the default value
158
+ var = 67,
159
+ //reserve a new variable in the stack
160
+ loads = 68,
161
+ //pushes to the stack a referenced value in the stack. has 2 parameters: <frame> <index>, frame is a negative offset to the frame, and index the index of the stack entry withing the referenced frame
162
+ indexAccess = 69,
163
+ //T['string'], 2 items on the stack
164
+ keyof = 70,
165
+ //keyof operator
166
+ infer = 71,
167
+ //2 params, like `loads`
168
+ typeof = 72,
169
+ //1 parameter that points to a function returning the runtime value from which we need to extract the type
170
+ condition = 73,
171
+ jumpCondition = 74,
172
+ //@deprecated. used when INFER is used in `extends` conditional branch. 2 args: left program, right program
173
+ jump = 75,
174
+ //jump to an address
175
+ call = 76,
176
+ //has one parameter, the next program address. creates a new stack frame with current program address as first stack entry, and jumps back to that + 1.
177
+ inline = 77,
178
+ inlineCall = 78,
179
+ distribute = 79,
180
+ //has one parameter, the co-routine program index.
181
+ extends = 80,
182
+ //X extends Y in a conditional type, XY popped from the stack, pushes boolean on the stack
183
+ widen = 81,
184
+ //widens the type on the stack, .e.g 'asd' => string, 34 => number, etc. this is necessary for infer runtime data, and widen if necessary (object member or non-contained literal)
185
+ static = 82,
186
+ mappedType2 = 83,
187
+ //same as mappedType2 but the given functionPointer returns a tuple [type, name]
188
+ functionReference = 84,
189
+ //Same as classReference but for functions
190
+ callSignature = 85,
191
+ //Same as function but for call signatures (in object literals)
192
+ /**
193
+ * Assign for Enum, Interface, Class, and TypeAlias declaration at the very end
194
+ * of the program the typeName. This is so that we have type names available even
195
+ * if the JS code is minified.
196
+ *
197
+ * his operator also assigns originTypes to the type, as it acts as the finalization
198
+ * step of a type.
199
+ */
200
+ typeName = 86,
201
+ //has one parameter, the index of the stack entry that contains the type name. Uses current head of the stack as type and assigns typeName to it.
202
+ /**
203
+ * If a class implement an interface or type,
204
+ *
205
+ * e.g. `class A implements B`, then B is on the stack and implements pops() it, and then assigns to A.implements = [B].
206
+ *
207
+ * This is only emitted when the class that is currently being described actually implements something.
208
+ *
209
+ * This OP has 1 argument and pops x types from the stack. X is the first argument.
210
+ * Expects a TypeClass on the stack.
211
+ */
212
+ implements = 87,
213
+ //pops one type from the stack and assigns it to the latest class on the stack as `implements` type.
214
+ nominal = 88,
215
+ //marks the last type on the stack as nominal. (used at the end of class/interface/type alias programs).
216
+ /**
217
+ * Custom Storm Software operators
218
+ */
219
+ tags = 89
220
+ }
221
+ //#endregion
222
+ export { ReflectionOp as n, TypeNumberBrand as r, MappedModifier as t };
223
+ //# sourceMappingURL=type-DEpHWwMt.d.mts.map
@@ -187,4 +187,5 @@ var ReflectionOp;
187
187
  })(ReflectionOp || (ReflectionOp = {}));
188
188
 
189
189
  //#endregion
190
- export { TypeNumberBrand as n, ReflectionOp as t };
190
+ export { TypeNumberBrand as n, ReflectionOp as t };
191
+ //# sourceMappingURL=type-Dgeqs-rL.mjs.map
@@ -1,192 +1,2 @@
1
- export declare const enum MappedModifier {
2
- optional = 1,
3
- removeOptional = 2,
4
- readonly = 4,
5
- removeReadonly = 8
6
- }
7
- /**
8
- * note: Checks are based on range checks (>, <, etc), so when adding
9
- * new types a check is required for all code using `TypeNumberBrand`.
10
- */
11
- export declare enum TypeNumberBrand {
12
- integer = 0,
13
- int8 = 1,
14
- int16 = 2,
15
- int32 = 3,
16
- uint8 = 4,
17
- uint16 = 5,
18
- uint32 = 6,
19
- float = 7,
20
- float32 = 8,
21
- float64 = 9
22
- }
23
- /**
24
- * The instruction set.
25
- * Should not be greater than 93 members, because we encode it via charCode starting at 33. +93 means we end up with charCode=126
26
- * (which is '~' and the last char that can be represented without \x. The next 127 is '\x7F').
27
- */
28
- export declare enum ReflectionOp {
29
- never = 0,
30
- any = 1,
31
- unknown = 2,
32
- void = 3,
33
- object = 4,
34
- string = 5,
35
- number = 6,
36
- numberBrand = 7,
37
- boolean = 8,
38
- bigint = 9,
39
- symbol = 10,
40
- null = 11,
41
- undefined = 12,
42
- /**
43
- * The literal type of string, number, or boolean.
44
- *
45
- * This OP has 1 parameter. The next byte is the absolute address of the literal on the stack, which is the actual literal value.
46
- *
47
- * Pushes a function type.
48
- */
49
- literal = 13,
50
- /**
51
- * This OP pops all types on the current stack frame.
52
- *
53
- * This OP has 1 parameter. The next byte is the absolute address of a string|number|symbol entry on the stack.
54
- *
55
- * Pushes a function type.
56
- */
57
- function = 14,
58
- /**
59
- * This OP pops all types on the current stack frame.
60
- *
61
- * Pushes a method type.
62
- */
63
- method = 15,
64
- methodSignature = 16,//has 1 parameter, reference to stack for its property name
65
- parameter = 17,
66
- /**
67
- * This OP pops the latest type entry on the stack.
68
- *
69
- * Pushes a property type.
70
- */
71
- property = 18,
72
- propertySignature = 19,//has 1 parameter, reference to stack for its property name
73
- /**
74
- * This OP pops all types on the current stack frame. Those types should be method|property.
75
- *
76
- * Pushes a TypeClass onto the stack.
77
- */
78
- class = 20,
79
- /**
80
- * If a class extends another class with generics, this OP represents the generic type arguments of the super class.
81
- *
82
- * e.g. `class A extends B<string, boolean>`, string and boolean are on the stack and classExtends pops() them, and then assigns to A.extendsTypeArguments = [string, boolean].
83
- *
84
- * This is only emitted when the class that is currently being described actually extends another class and uses generics.
85
- *
86
- * This OP has 1 argument and pops x types from the stack. X is the first argument.
87
- * Expects a TypeClass on the stack.
88
- */
89
- classExtends = 21,
90
- /**
91
- * This OP has 1 parameter, the stack entry to the actual class symbol.
92
- */
93
- classReference = 22,
94
- /**
95
- * Marks the last entry in the stack as optional. Used for method|property. Equal to the QuestionMark operator in a property assignment.
96
- */
97
- optional = 23,
98
- readonly = 24,
99
- public = 25,
100
- private = 26,
101
- protected = 27,
102
- abstract = 28,
103
- defaultValue = 29,
104
- description = 30,
105
- rest = 31,
106
- regexp = 32,
107
- enum = 33,
108
- enumMember = 34,//has one argument, the name.
109
- set = 35,
110
- map = 36,
111
- /**
112
- * Pops the latest stack entry and uses it as T for an array type.
113
- *
114
- * Pushes an array type.
115
- */
116
- array = 37,
117
- tuple = 38,
118
- tupleMember = 39,
119
- namedTupleMember = 40,//has one argument, the name.
120
- union = 41,//pops frame. requires frame start when stack can be dirty.
121
- intersection = 42,
122
- indexSignature = 43,
123
- objectLiteral = 44,
124
- mappedType = 45,//2 parameters: functionPointer and modifier.
125
- in = 46,
126
- frame = 47,//creates a new stack frame
127
- moveFrame = 48,//pop() as T, pops the current stack frame, push(T)
128
- return = 49,
129
- templateLiteral = 50,
130
- date = 51,
131
- int8Array = 52,
132
- uint8ClampedArray = 53,
133
- uint8Array = 54,
134
- int16Array = 55,
135
- uint16Array = 56,
136
- int32Array = 57,
137
- uint32Array = 58,
138
- float32Array = 59,
139
- float64Array = 60,
140
- bigInt64Array = 61,
141
- arrayBuffer = 62,
142
- promise = 63,
143
- arg = 64,//@deprecated. parameter is a number referencing an entry in the stack, relative to the beginning of the current frame, *-1. pushes that entry onto the stack. this is related to the calling convention.
144
- typeParameter = 65,//generic type parameter, e.g. T in a generic. has 1 parameter: reference to the name.
145
- typeParameterDefault = 66,//generic type parameter with a default value, e.g. T in a generic. has 1 parameter: reference to the name. pop() for the default value
146
- var = 67,//reserve a new variable in the stack
147
- loads = 68,//pushes to the stack a referenced value in the stack. has 2 parameters: <frame> <index>, frame is a negative offset to the frame, and index the index of the stack entry withing the referenced frame
148
- indexAccess = 69,//T['string'], 2 items on the stack
149
- keyof = 70,//keyof operator
150
- infer = 71,//2 params, like `loads`
151
- typeof = 72,//1 parameter that points to a function returning the runtime value from which we need to extract the type
152
- condition = 73,
153
- jumpCondition = 74,//@deprecated. used when INFER is used in `extends` conditional branch. 2 args: left program, right program
154
- jump = 75,//jump to an address
155
- call = 76,//has one parameter, the next program address. creates a new stack frame with current program address as first stack entry, and jumps back to that + 1.
156
- inline = 77,
157
- inlineCall = 78,
158
- distribute = 79,//has one parameter, the co-routine program index.
159
- extends = 80,//X extends Y in a conditional type, XY popped from the stack, pushes boolean on the stack
160
- widen = 81,//widens the type on the stack, .e.g 'asd' => string, 34 => number, etc. this is necessary for infer runtime data, and widen if necessary (object member or non-contained literal)
161
- static = 82,
162
- mappedType2 = 83,//same as mappedType2 but the given functionPointer returns a tuple [type, name]
163
- functionReference = 84,//Same as classReference but for functions
164
- callSignature = 85,//Same as function but for call signatures (in object literals)
165
- /**
166
- * Assign for Enum, Interface, Class, and TypeAlias declaration at the very end
167
- * of the program the typeName. This is so that we have type names available even
168
- * if the JS code is minified.
169
- *
170
- * his operator also assigns originTypes to the type, as it acts as the finalization
171
- * step of a type.
172
- */
173
- typeName = 86,//has one parameter, the index of the stack entry that contains the type name. Uses current head of the stack as type and assigns typeName to it.
174
- /**
175
- * If a class implement an interface or type,
176
- *
177
- * e.g. `class A implements B`, then B is on the stack and implements pops() it, and then assigns to A.implements = [B].
178
- *
179
- * This is only emitted when the class that is currently being described actually implements something.
180
- *
181
- * This OP has 1 argument and pops x types from the stack. X is the first argument.
182
- * Expects a TypeClass on the stack.
183
- */
184
- implements = 87,//pops one type from the stack and assigns it to the latest class on the stack as `implements` type.
185
- nominal = 88,//marks the last type on the stack as nominal. (used at the end of class/interface/type alias programs).
186
- /**
187
- * Custom Storm Software operators
188
- */
189
- tags = 89
190
- }
191
-
192
- export {};
1
+ import { n as ReflectionOp, r as TypeNumberBrand, t as MappedModifier } from "./type-2yMJb9Mw.cjs";
2
+ export { MappedModifier, ReflectionOp, TypeNumberBrand };