ranger-compiler 3.2.0 → 3.5.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/CHANGELOG.md +2463 -0
- package/LICENSE +28 -0
- package/LICENSE-MIT +21 -0
- package/README.md +1651 -1895
- package/dist/Lang.rgr +10946 -5852
- package/dist/README.md +3 -2
- package/dist/api.d.ts +1548 -27
- package/dist/api.js +70572 -38295
- package/dist/git-http.mjs +126 -0
- package/dist/lib/ACEEditor.rgr +2 -0
- package/dist/lib/Ajax.rgr +2 -0
- package/dist/lib/CmdParams.rgr +2 -0
- package/dist/lib/Crypto.rgr +2 -0
- package/dist/lib/DOMLib.rgr +2 -0
- package/dist/lib/Engine3D.rgr +2 -0
- package/dist/lib/ImmutableVector.rgr +2 -0
- package/dist/lib/IndexedDB.rgr +2 -0
- package/dist/lib/IsoDate/DateMath.rgr +2 -0
- package/dist/lib/IsoDate/IsoCalendar.rgr +2 -0
- package/dist/lib/IsoDate/IsoDateParse.rgr +2 -0
- package/dist/lib/IsoDateLib.rgr +2 -0
- package/dist/lib/JSON.rgr +4906 -48
- package/dist/lib/JinxProcess.rgr +2 -0
- package/dist/lib/RangerProcess.rgr +2 -0
- package/dist/lib/Regex/RegexMatch.rgr +2 -0
- package/dist/lib/RegexLib.rgr +2 -0
- package/dist/lib/SQL.rgr +2 -0
- package/dist/lib/ServiceLib.rgr +2 -0
- package/dist/lib/Shell.rgr +326 -0
- package/dist/lib/Storage.rgr +2 -0
- package/dist/lib/Time.rgr +2 -0
- package/dist/lib/Timers.rgr +2 -0
- package/dist/lib/TypedArrays.rgr +2 -0
- package/dist/lib/ViewLib.rgr +2 -0
- package/dist/lib/WebLib.rgr +2 -0
- package/dist/lib/WebServerLib.rgr +2 -0
- package/dist/lib/apple/AppleAppBuilder.rgr +572 -0
- package/dist/lib/apple/AppleAppSpec.rgr +201 -0
- package/dist/lib/apple/AppleDevice.rgr +295 -0
- package/dist/lib/apple/AppleDeviceDoctor.rgr +453 -0
- package/dist/lib/apple/AppleSigning.rgr +379 -0
- package/dist/lib/apple/AppleSimulator.rgr +248 -0
- package/dist/lib/apple/AppleTarget.rgr +185 -0
- package/dist/lib/apple/AppleToolchain.rgr +458 -0
- package/dist/lib/apple/README.md +311 -0
- package/dist/lib/apple/apple_test.rgr +669 -0
- package/dist/lib/core/README.md +251 -0
- package/dist/lib/core/RgBase.rgr +313 -0
- package/dist/lib/core/RgNum.rgr +653 -0
- package/dist/lib/core/RgText.rgr +680 -0
- package/dist/lib/core/RgU32.rgr +309 -0
- package/dist/lib/ranger-dir.rgr +2 -0
- package/dist/lib/shell_test.rgr +193 -0
- package/dist/lib/stdlib.rgr +1176 -665
- package/dist/lib/stdops.rgr +2 -0
- package/dist/lib/zip/Inflate.rgr +675 -0
- package/dist/lib/zip/ZipBuffer.rgr +358 -0
- package/dist/package.json +1 -1
- package/dist/rgrc.js +76333 -40647
- package/dist/stdops.rgr +2 -0
- package/package.json +1121 -339
package/dist/api.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
type union_Any = CmdParams | test_cmdparams | InputFSFolder | InputFSFile | InputEnv | test_input_filesystem | RangerAppTodo | RangerCompilerMessage | RangerParamEventHandler | RangerParamEventList | RangerParamEventMap | RangerAppArrayValue | RangerAppHashValue | RangerAppValue | RangerRefForce | RangerAppParamDesc | RangerAppFunctionDesc | RangerAppMethodVariants | RangerAppInterfaceImpl | RangerTraitParams | RangerAppClassDesc | RangerTypeClass | SourceCode | CodeNodeLiteral | CodeNode | TTypeRegistry | TypeCounts | RangerNodeValue | RangerBackReference | RangerAppEnum | OpFindResult | RangerOperatorList | RangerNodeList | ContextTransaction | ContextTransactionMutation | RangerRegisteredPlugin | RangerAppWriterContext | SourceMapEntry | SourceMapBuilder | CodeFile | CodeFileSystem | CodeSlice | CodeWriter | RangerLispParser | TTypes | RangerArgMatch | DictNode | RangerSerializeClass | RangerImmutableExtension | RangerProcessLifecycle | RangerProcessClass | RangerProcessProcSend | RangerProcessProcStartCheck | RangerProcessCodegen | RangerServiceBuilder | RangerAppOperatorDesc | TFiles | ClassJoinPoint | WalkLater | RangerFlowParser | TFactory | CallChain | NodeEvalState | RangerGenericClassWriter | AndroidPageWriter | RangerJava7ClassWriter | RangerSwift3ClassWriter | RangerSwift6ClassWriter | RangerCppClassWriter | MethodCallList | RangerRustClassWriter | RangerKotlinClassWriter | RangerCSharpClassWriter | RangerScalaClassWriter | RangerGolangClassWriter | RangerGolangHttpServerWriter | RangerPHPClassWriter | RangerPythonClassWriter | WebPageWriter | RangerJavaScriptClassWriter | RangerRangerClassWriter | LowIRUtil | LowIRParam | LowIRInstr | LowIRBlock | LowIRFunction | LowIRField | LowIRTypeFieldDesc | LowIRTypeDesc | LowIRStruct | LowIRStringGlobal | LowIRExternDecl | LowIRModule | LowIRSession | LowIRBuilder | LowIRRuntimeGen | LowIRTarget | LowIRLowerContext | LambdaCaptureInfo | LowIRBuilderPass | LLVMIRWriter | WATWriter | RangerLLVMPipeline | RangerLLVMClassWriter | OpList | RangerActiveOperators | LiveCompiler | ColorConsole | CLIProgress | RangerDocGenerator | StaticAnalyzer | viewbuilder_Android | viewbuilder_Web | CompilerResults | VirtualCompiler | CompilerInterface | number | string | boolean | number;
|
|
2
1
|
export declare class CmdParams {
|
|
3
2
|
flags: {
|
|
4
3
|
[key: string]: boolean;
|
|
@@ -12,7 +11,7 @@ export declare class CmdParams {
|
|
|
12
11
|
getParam(name: string): string | undefined;
|
|
13
12
|
collect(): void;
|
|
14
13
|
toDictionary(): Record<string, any>;
|
|
15
|
-
static fromDictionary(dict: Record<string, any>):
|
|
14
|
+
static fromDictionary(dict: Record<string, any>): CmdParams;
|
|
16
15
|
}
|
|
17
16
|
export declare class test_cmdparams {
|
|
18
17
|
constructor();
|
|
@@ -28,7 +27,7 @@ export declare class InputFSFolder {
|
|
|
28
27
|
constructor();
|
|
29
28
|
forTree(cb: (item: InputFSFolder) => void): void;
|
|
30
29
|
toDictionary(): Record<string, any>;
|
|
31
|
-
static fromDictionary(dict: Record<string, any>):
|
|
30
|
+
static fromDictionary(dict: Record<string, any>): InputFSFolder;
|
|
32
31
|
}
|
|
33
32
|
export declare class InputFSFile {
|
|
34
33
|
name: string;
|
|
@@ -39,6 +38,23 @@ export declare class InputFSFile {
|
|
|
39
38
|
toDictionary(): Record<string, any>;
|
|
40
39
|
static fromDictionary(dict: Record<string, any>): InputFSFile;
|
|
41
40
|
}
|
|
41
|
+
export declare class InputFileResolver {
|
|
42
|
+
files: {
|
|
43
|
+
[key: string]: string;
|
|
44
|
+
};
|
|
45
|
+
hostDirs: Array<string>;
|
|
46
|
+
constructor();
|
|
47
|
+
putFile(name: string, data: string): void;
|
|
48
|
+
addHostDir(dir: string): void;
|
|
49
|
+
knownName(name: string): boolean;
|
|
50
|
+
baseName(path: string): string;
|
|
51
|
+
exists(path: string, name: string): boolean;
|
|
52
|
+
tryRead(path: string, name: string): Promise<string> | undefined;
|
|
53
|
+
hostHas(name: string): boolean;
|
|
54
|
+
hostRead(name: string): Promise<string> | undefined;
|
|
55
|
+
toDictionary(): Record<string, any>;
|
|
56
|
+
static fromDictionary(dict: Record<string, any>): InputFileResolver;
|
|
57
|
+
}
|
|
42
58
|
export declare class InputEnv {
|
|
43
59
|
use_real: boolean;
|
|
44
60
|
filesystem?: InputFSFolder;
|
|
@@ -46,10 +62,12 @@ export declare class InputEnv {
|
|
|
46
62
|
[key: string]: string;
|
|
47
63
|
};
|
|
48
64
|
commandLine?: CmdParams;
|
|
65
|
+
resolver?: InputFileResolver;
|
|
49
66
|
constructor();
|
|
50
67
|
setEnv(name: string, value: string): void;
|
|
68
|
+
setResolver(r: InputFileResolver): void;
|
|
51
69
|
toDictionary(): Record<string, any>;
|
|
52
|
-
static fromDictionary(dict: Record<string, any>):
|
|
70
|
+
static fromDictionary(dict: Record<string, any>): InputEnv;
|
|
53
71
|
}
|
|
54
72
|
export declare class test_input_filesystem {
|
|
55
73
|
constructor();
|
|
@@ -67,6 +85,218 @@ export declare class RangerCompilerMessage {
|
|
|
67
85
|
node?: CodeNode;
|
|
68
86
|
constructor();
|
|
69
87
|
}
|
|
88
|
+
export declare class RangerDocParam {
|
|
89
|
+
name: string;
|
|
90
|
+
text: string;
|
|
91
|
+
node?: CodeNode;
|
|
92
|
+
constructor();
|
|
93
|
+
}
|
|
94
|
+
export declare class RangerDocDeprecation {
|
|
95
|
+
since: string;
|
|
96
|
+
use: string;
|
|
97
|
+
description: string;
|
|
98
|
+
constructor();
|
|
99
|
+
}
|
|
100
|
+
export declare class RangerDocBlock {
|
|
101
|
+
is_public: boolean;
|
|
102
|
+
is_internal: boolean;
|
|
103
|
+
is_experimental: boolean;
|
|
104
|
+
description: string;
|
|
105
|
+
params: Array<RangerDocParam>;
|
|
106
|
+
returns: string;
|
|
107
|
+
throws: Array<string>;
|
|
108
|
+
since: string;
|
|
109
|
+
is_deprecated: boolean;
|
|
110
|
+
deprecation?: RangerDocDeprecation;
|
|
111
|
+
see: Array<string>;
|
|
112
|
+
examples: Array<string>;
|
|
113
|
+
exampleRefs: Array<string>;
|
|
114
|
+
category: string;
|
|
115
|
+
platform: string;
|
|
116
|
+
attrs: Array<string>;
|
|
117
|
+
targets: {
|
|
118
|
+
[key: string]: RangerDocBlock;
|
|
119
|
+
};
|
|
120
|
+
targetNames: Array<string>;
|
|
121
|
+
node?: CodeNode;
|
|
122
|
+
constructor();
|
|
123
|
+
hasParamDoc(n: string): boolean;
|
|
124
|
+
paramText(n: string): string;
|
|
125
|
+
hasTargetView(name: string): boolean;
|
|
126
|
+
viewFor(name: string): RangerDocBlock;
|
|
127
|
+
}
|
|
128
|
+
export declare class RangerDocReader {
|
|
129
|
+
constructor();
|
|
130
|
+
wordAt(node: CodeNode, idx: number): string;
|
|
131
|
+
textFrom(node: CodeNode, startIndex: number): string;
|
|
132
|
+
blockArgOf(node: CodeNode): CodeNode;
|
|
133
|
+
hasBlockArg(node: CodeNode): boolean;
|
|
134
|
+
readDeprecation(blockNode: CodeNode, ctx: RangerAppWriterContext): RangerDocDeprecation;
|
|
135
|
+
fill(doc: RangerDocBlock, blockNode: CodeNode, ctx: RangerAppWriterContext, allowTargets: boolean): void;
|
|
136
|
+
read(blockNode: CodeNode, ctx: RangerAppWriterContext): RangerDocBlock;
|
|
137
|
+
}
|
|
138
|
+
export declare class RangerApiParam {
|
|
139
|
+
name: string;
|
|
140
|
+
compiledName: string;
|
|
141
|
+
typeName: string;
|
|
142
|
+
description: string;
|
|
143
|
+
constructor();
|
|
144
|
+
}
|
|
145
|
+
export declare class RangerApiMethod {
|
|
146
|
+
name: string;
|
|
147
|
+
compiledName: string;
|
|
148
|
+
is_static: boolean;
|
|
149
|
+
is_constructor: boolean;
|
|
150
|
+
is_public: boolean;
|
|
151
|
+
returnType: string;
|
|
152
|
+
returnDoc: string;
|
|
153
|
+
params: Array<RangerApiParam>;
|
|
154
|
+
doc?: RangerDocBlock;
|
|
155
|
+
has_doc: boolean;
|
|
156
|
+
node?: CodeNode;
|
|
157
|
+
constructor();
|
|
158
|
+
}
|
|
159
|
+
export declare class RangerApiField {
|
|
160
|
+
name: string;
|
|
161
|
+
compiledName: string;
|
|
162
|
+
typeName: string;
|
|
163
|
+
is_public: boolean;
|
|
164
|
+
is_static: boolean;
|
|
165
|
+
doc?: RangerDocBlock;
|
|
166
|
+
has_doc: boolean;
|
|
167
|
+
constructor();
|
|
168
|
+
}
|
|
169
|
+
export declare class RangerApiClass {
|
|
170
|
+
name: string;
|
|
171
|
+
compiledName: string;
|
|
172
|
+
kind: string;
|
|
173
|
+
is_public: boolean;
|
|
174
|
+
extendsName: string;
|
|
175
|
+
fields: Array<RangerApiField>;
|
|
176
|
+
methods: Array<RangerApiMethod>;
|
|
177
|
+
doc?: RangerDocBlock;
|
|
178
|
+
has_doc: boolean;
|
|
179
|
+
node?: CodeNode;
|
|
180
|
+
constructor();
|
|
181
|
+
hasPublicMember(): boolean;
|
|
182
|
+
}
|
|
183
|
+
export declare class RangerApiModel {
|
|
184
|
+
moduleName: string;
|
|
185
|
+
version: string;
|
|
186
|
+
description: string;
|
|
187
|
+
classes: Array<RangerApiClass>;
|
|
188
|
+
warnings: Array<string>;
|
|
189
|
+
constructor();
|
|
190
|
+
publicClassCount(): number;
|
|
191
|
+
}
|
|
192
|
+
export declare class RangerApiBuilder {
|
|
193
|
+
strict: boolean;
|
|
194
|
+
publicClassNames: {
|
|
195
|
+
[key: string]: boolean;
|
|
196
|
+
};
|
|
197
|
+
internalClassNames: {
|
|
198
|
+
[key: string]: boolean;
|
|
199
|
+
};
|
|
200
|
+
exampleFns: Array<RangerAppFunctionDesc>;
|
|
201
|
+
constructor();
|
|
202
|
+
typeNameOf(node: CodeNode): string;
|
|
203
|
+
readDocOf(node: CodeNode, ctx: RangerAppWriterContext): RangerDocBlock;
|
|
204
|
+
warn(model: RangerApiModel, ctx: RangerAppWriterContext, node: CodeNode, msg: string): void;
|
|
205
|
+
validateMethod(model: RangerApiModel, m: RangerApiMethod, ctx: RangerAppWriterContext): void;
|
|
206
|
+
typeNamesOf(node: CodeNode): Array<string>;
|
|
207
|
+
checkNoLeak(ctx: RangerAppWriterContext, node: CodeNode, what: string, role: string, typeNode: CodeNode): void;
|
|
208
|
+
buildMethod(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, isStatic: boolean): RangerApiMethod;
|
|
209
|
+
checkMethodLeaks(m: RangerApiMethod, fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext): void;
|
|
210
|
+
build(ctx: RangerAppWriterContext): RangerApiModel;
|
|
211
|
+
findExampleFn(ctx: RangerAppWriterContext, name: string): RangerAppFunctionDesc;
|
|
212
|
+
markExamplesOf(doc: RangerDocBlock, owner: CodeNode, ctx: RangerAppWriterContext): void;
|
|
213
|
+
resolveExamples(model: RangerApiModel, ctx: RangerAppWriterContext): void;
|
|
214
|
+
}
|
|
215
|
+
export declare class RangerDocCommentWriter {
|
|
216
|
+
exampleTexts: Array<string>;
|
|
217
|
+
constructor();
|
|
218
|
+
clearExamples(): void;
|
|
219
|
+
loadExamples(doc: RangerDocBlock, ctx: RangerAppWriterContext): void;
|
|
220
|
+
allExamples(doc: RangerDocBlock): Array<string>;
|
|
221
|
+
jsTypeName(t: string): string;
|
|
222
|
+
jsTypeOf(node: CodeNode): string;
|
|
223
|
+
csTypeName(t: string): string;
|
|
224
|
+
xmlEscape(value: string): string;
|
|
225
|
+
linesOf(text: string): Array<string>;
|
|
226
|
+
writeJsDoc(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, wr: CodeWriter): void;
|
|
227
|
+
writeJsDocTyped(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, valueType: string, wr: CodeWriter): void;
|
|
228
|
+
writeXmlLines(tag: string, attrs: string, text: string, wr: CodeWriter): void;
|
|
229
|
+
writeCsDoc(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, wr: CodeWriter): void;
|
|
230
|
+
writeCsAttrs(doc: RangerDocBlock, wr: CodeWriter): void;
|
|
231
|
+
swiftTypeName(t: string): string;
|
|
232
|
+
writeSwiftDoc(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, wr: CodeWriter): void;
|
|
233
|
+
writeSwiftAttrs(doc: RangerDocBlock, wr: CodeWriter): void;
|
|
234
|
+
kotlinTypeName(t: string): string;
|
|
235
|
+
writeKotlinDoc(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, wr: CodeWriter): void;
|
|
236
|
+
writeKotlinAttrs(doc: RangerDocBlock, replaceWith: string, wr: CodeWriter): void;
|
|
237
|
+
pyTypeName(t: string): string;
|
|
238
|
+
pyTypeOf(node: CodeNode): string;
|
|
239
|
+
writePyDoc(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, wr: CodeWriter): void;
|
|
240
|
+
dartTypeName(t: string): string;
|
|
241
|
+
writeDartDoc(doc: RangerDocBlock, retType: string, params: Array<RangerApiParam>, wr: CodeWriter): void;
|
|
242
|
+
writeDartAttrs(doc: RangerDocBlock, wr: CodeWriter): void;
|
|
243
|
+
paramsOf(fd: RangerAppFunctionDesc, doc: RangerDocBlock, forJs: boolean): Array<RangerApiParam>;
|
|
244
|
+
writeJsDocForMethod(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
245
|
+
writeCsDocForMethod(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
246
|
+
writeJsDocForClass(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
247
|
+
writeCsDocForClass(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
248
|
+
writeSwiftDocForMethod(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
249
|
+
writeSwiftDocForClass(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
250
|
+
writeSwiftDocForField(p: RangerAppParamDesc, wr: CodeWriter): void;
|
|
251
|
+
kotlinReplaceWith(cl: RangerAppClassDesc, doc: RangerDocBlock): string;
|
|
252
|
+
writeKotlinDocForMethod(cl: RangerAppClassDesc, fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
253
|
+
writeKotlinDocForClass(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
254
|
+
writeKotlinDocForField(p: RangerAppParamDesc, wr: CodeWriter): void;
|
|
255
|
+
writePyDocForMethod(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
256
|
+
writePyDocForClass(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
257
|
+
writeDartDocForMethod(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
258
|
+
writeDartDocForClass(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
259
|
+
writeDartDocForField(p: RangerAppParamDesc, wr: CodeWriter): void;
|
|
260
|
+
memberVisibility(cl: RangerAppClassDesc, member: RangerAppParamDesc, whenLegacy: string, whenPublic: string, whenInternal: string): string;
|
|
261
|
+
classVisibility(cl: RangerAppClassDesc, whenLegacy: string, whenPublic: string, whenInternal: string): string;
|
|
262
|
+
writeJsDocForField(p: RangerAppParamDesc, wr: CodeWriter): void;
|
|
263
|
+
writeCsDocForField(p: RangerAppParamDesc, wr: CodeWriter): void;
|
|
264
|
+
static lookupFn(ctx: RangerAppWriterContext, name: string): RangerAppFunctionDesc;
|
|
265
|
+
}
|
|
266
|
+
export declare class RangerApiArtifactWriter {
|
|
267
|
+
constructor();
|
|
268
|
+
jsonEscape(value: string): string;
|
|
269
|
+
jsonString(value: string): string;
|
|
270
|
+
jsonBool(value: boolean): string;
|
|
271
|
+
jsonStringList(items: Array<string>): string;
|
|
272
|
+
docFields(doc: RangerDocBlock, has: boolean): string;
|
|
273
|
+
writeJson(model: RangerApiModel, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
274
|
+
writeMarkdown(model: RangerApiModel, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
275
|
+
writeReport(model: RangerApiModel, wr: CodeWriter): void;
|
|
276
|
+
writeAll(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
277
|
+
}
|
|
278
|
+
export declare class RangerApiPackageWriter {
|
|
279
|
+
constructor();
|
|
280
|
+
settingOr(ctx: RangerAppWriterContext, key: string, fallback: string): string;
|
|
281
|
+
jsonEscape(value: string): string;
|
|
282
|
+
writeNpmPackage(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
283
|
+
xmlEscape(value: string): string;
|
|
284
|
+
writeCsProject(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
285
|
+
writeDocFxConfig(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
286
|
+
writeDocFxHome(model: RangerApiModel, ctx: RangerAppWriterContext, name: string, orig_wr: CodeWriter): void;
|
|
287
|
+
swiftModuleName(raw: string): string;
|
|
288
|
+
writeSwiftPackage(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
289
|
+
writeDocCCatalog(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
290
|
+
writeKotlinGradle(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
291
|
+
writeDokkaModuleDoc(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
292
|
+
writeDartBarrel(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter, node: CodeNode): void;
|
|
293
|
+
pyModuleName(raw: string): string;
|
|
294
|
+
writePyProject(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
295
|
+
writePyAll(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
296
|
+
writeReadme(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
297
|
+
writeDartPubspec(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter): void;
|
|
298
|
+
writeAll(model: RangerApiModel, ctx: RangerAppWriterContext, orig_wr: CodeWriter, node: CodeNode): void;
|
|
299
|
+
}
|
|
70
300
|
export declare class RangerParamEventHandler {
|
|
71
301
|
constructor();
|
|
72
302
|
callback(param: RangerAppParamDesc): void;
|
|
@@ -130,6 +360,7 @@ export declare class RangerAppParamDesc {
|
|
|
130
360
|
debugString: string;
|
|
131
361
|
is_register: boolean;
|
|
132
362
|
ref_cnt: number;
|
|
363
|
+
read_cnt: number;
|
|
133
364
|
init_cnt: number;
|
|
134
365
|
set_cnt: number;
|
|
135
366
|
return_cnt: number;
|
|
@@ -162,14 +393,19 @@ export declare class RangerAppParamDesc {
|
|
|
162
393
|
escapes_function: boolean;
|
|
163
394
|
needs_cpp_reference: boolean;
|
|
164
395
|
rust_borrow_type: number;
|
|
396
|
+
needs_swift_inout: boolean;
|
|
397
|
+
rust_static_str: boolean;
|
|
398
|
+
rust_interior_cell: boolean;
|
|
165
399
|
rust_assigned_to_weak: boolean;
|
|
166
400
|
rust_needs_rc_wrap: boolean;
|
|
167
401
|
rust_assigned_to_field: boolean;
|
|
402
|
+
sharing_mutates: boolean;
|
|
168
403
|
ownership_kind: number;
|
|
169
404
|
ownership_resolved: boolean;
|
|
170
405
|
escapes_via: string;
|
|
171
406
|
escape_owners: Array<string>;
|
|
172
407
|
escape_via_call: boolean;
|
|
408
|
+
escape_return_only: boolean;
|
|
173
409
|
ownership_read_only: boolean;
|
|
174
410
|
node?: CodeNode;
|
|
175
411
|
nameNode?: CodeNode;
|
|
@@ -178,10 +414,15 @@ export declare class RangerAppParamDesc {
|
|
|
178
414
|
return_value?: RangerAppParamDesc;
|
|
179
415
|
description: string;
|
|
180
416
|
git_doc: string;
|
|
417
|
+
has_doc: boolean;
|
|
418
|
+
docBlock?: RangerDocBlock;
|
|
419
|
+
is_doc_example: boolean;
|
|
420
|
+
docExampleText: string;
|
|
181
421
|
has_events: boolean;
|
|
182
422
|
eMap?: RangerParamEventMap;
|
|
183
423
|
constructor();
|
|
184
424
|
addEvent(name: string, e: RangerParamEventHandler): void;
|
|
425
|
+
changeStrengthSelf(newStrength: number, lifeTime: number): void;
|
|
185
426
|
changeStrength(newStrength: number, lifeTime: number, changer: CodeNode): void;
|
|
186
427
|
isFunction(): boolean;
|
|
187
428
|
isProperty(): boolean;
|
|
@@ -231,6 +472,8 @@ export declare class RangerAppFunctionDesc extends RangerAppParamDesc {
|
|
|
231
472
|
all_paths_return: boolean;
|
|
232
473
|
mutates_self: boolean;
|
|
233
474
|
static_analysis_done: boolean;
|
|
475
|
+
rust_needs_self_rc: boolean;
|
|
476
|
+
rust_mut_self: boolean;
|
|
234
477
|
rust_uses_self: boolean;
|
|
235
478
|
rust_passes_self_to_weak: boolean;
|
|
236
479
|
rust_can_be_static: boolean;
|
|
@@ -241,13 +484,34 @@ export declare class RangerAppFunctionDesc extends RangerAppParamDesc {
|
|
|
241
484
|
mutates_param_indices: Array<number>;
|
|
242
485
|
constructor();
|
|
243
486
|
addCallTo(m: RangerAppFunctionDesc): void;
|
|
244
|
-
addIndirectClassUsage(m: RangerAppClassDesc, ctx: RangerAppWriterContext): void
|
|
245
|
-
addClassUsage(m: RangerAppClassDesc, ctx: RangerAppWriterContext): void
|
|
487
|
+
addIndirectClassUsage(m: RangerAppClassDesc, ctx: RangerAppWriterContext): Promise<void>;
|
|
488
|
+
addClassUsage(m: RangerAppClassDesc, ctx: RangerAppWriterContext): Promise<void>;
|
|
246
489
|
forOtherVersions(ctx: RangerAppWriterContext, cb: (item: RangerAppFunctionDesc) => void): Promise<void>;
|
|
247
490
|
isFunction(): boolean;
|
|
248
491
|
isClass(): boolean;
|
|
249
492
|
isProperty(): boolean;
|
|
250
493
|
}
|
|
494
|
+
export declare class ShapeViewDesc {
|
|
495
|
+
shapeName: string;
|
|
496
|
+
viewKind: string;
|
|
497
|
+
viewName: string;
|
|
498
|
+
className: string;
|
|
499
|
+
allowedCases: Array<string>;
|
|
500
|
+
parentView: string;
|
|
501
|
+
methodNames: Array<string>;
|
|
502
|
+
requiredMethods: Array<string>;
|
|
503
|
+
constructor();
|
|
504
|
+
}
|
|
505
|
+
export declare class ShapeGroupMethodSlot {
|
|
506
|
+
declaringGroup: string;
|
|
507
|
+
methodName: string;
|
|
508
|
+
isRequired: boolean;
|
|
509
|
+
hasDefault: boolean;
|
|
510
|
+
defaultNode?: CodeNode;
|
|
511
|
+
implCaseNames: Array<string>;
|
|
512
|
+
implNodes: Array<CodeNode>;
|
|
513
|
+
constructor();
|
|
514
|
+
}
|
|
251
515
|
export declare class RangerAppMethodVariants {
|
|
252
516
|
name: string;
|
|
253
517
|
variants: Array<RangerAppFunctionDesc>;
|
|
@@ -326,10 +590,17 @@ export declare class RangerAppClassDesc extends RangerAppParamDesc {
|
|
|
326
590
|
is_inherited: boolean;
|
|
327
591
|
is_extended_by_children: boolean;
|
|
328
592
|
child_classes: Array<string>;
|
|
593
|
+
rust_trait_mut: {
|
|
594
|
+
[key: string]: boolean;
|
|
595
|
+
};
|
|
596
|
+
rust_trait_mut_ready: boolean;
|
|
597
|
+
rust_needs_ref_semantics: boolean;
|
|
598
|
+
rust_ref_reason: string;
|
|
329
599
|
constructor();
|
|
330
600
|
isClass(): boolean;
|
|
331
601
|
isProperty(): boolean;
|
|
332
602
|
doesInherit(): boolean;
|
|
603
|
+
isDocExampleOnly(): boolean;
|
|
333
604
|
isNormalClass(): boolean;
|
|
334
605
|
getSystemclassType(): string;
|
|
335
606
|
isSystemclassType(typeName: string): boolean;
|
|
@@ -362,7 +633,7 @@ export declare class RangerTypeClass {
|
|
|
362
633
|
implements_interfaces: Array<RangerTypeClass>;
|
|
363
634
|
extends_classes: Array<RangerTypeClass>;
|
|
364
635
|
belongs_to_union: Array<RangerTypeClass>;
|
|
365
|
-
description?:
|
|
636
|
+
description?: any;
|
|
366
637
|
is_empty: boolean;
|
|
367
638
|
is_primitive: boolean;
|
|
368
639
|
is_mutable: boolean;
|
|
@@ -416,7 +687,7 @@ export declare class CodeNodeLiteral {
|
|
|
416
687
|
attrs: Array<CodeNodeLiteral>;
|
|
417
688
|
constructor();
|
|
418
689
|
toDictionary(): Record<string, any>;
|
|
419
|
-
static fromDictionary(dict: Record<string, any>):
|
|
690
|
+
static fromDictionary(dict: Record<string, any>): CodeNodeLiteral;
|
|
420
691
|
}
|
|
421
692
|
export declare class CodeNode {
|
|
422
693
|
code?: SourceCode;
|
|
@@ -441,9 +712,11 @@ export declare class CodeNode {
|
|
|
441
712
|
has_lambda: boolean;
|
|
442
713
|
has_lambda_call: boolean;
|
|
443
714
|
has_call: boolean;
|
|
715
|
+
is_call_args: boolean;
|
|
444
716
|
rust_needs_preevaluate: boolean;
|
|
445
717
|
rust_preevaluated_args: Array<CodeNode>;
|
|
446
718
|
rust_use_tmpvar: string;
|
|
719
|
+
rust_is_tail_return: boolean;
|
|
447
720
|
operator_pred: number;
|
|
448
721
|
to_the_right: boolean;
|
|
449
722
|
right_node?: CodeNode;
|
|
@@ -498,6 +771,8 @@ export declare class CodeNode {
|
|
|
498
771
|
fnDesc?: RangerAppFunctionDesc;
|
|
499
772
|
lambdaFnDesc?: RangerAppFunctionDesc;
|
|
500
773
|
hasParamDesc: boolean;
|
|
774
|
+
has_doc_tail: boolean;
|
|
775
|
+
docNode?: CodeNode;
|
|
501
776
|
paramDesc?: RangerAppParamDesc;
|
|
502
777
|
ownParamDesc?: RangerAppParamDesc;
|
|
503
778
|
evalCtx?: RangerAppWriterContext;
|
|
@@ -561,6 +836,7 @@ export declare class CodeNode {
|
|
|
561
836
|
isParsedAsPrimitive(): boolean;
|
|
562
837
|
isPrimitiveType(): boolean;
|
|
563
838
|
isAPrimitiveType(): boolean;
|
|
839
|
+
rangerDoubleLiteral(v: number): string;
|
|
564
840
|
writeCode(wr: CodeWriter): void;
|
|
565
841
|
createChainTarget(): void;
|
|
566
842
|
inferDefExpressionTypeFromValue(node: CodeNode): void;
|
|
@@ -577,6 +853,7 @@ export declare class CodeNode {
|
|
|
577
853
|
newExpressionNode(): CodeNode;
|
|
578
854
|
getChildrenFrom(otherNode: CodeNode): void;
|
|
579
855
|
finalizeAsCallChainRoot(): void;
|
|
856
|
+
chainDotName(item: CodeNode): string;
|
|
580
857
|
tryDesugarNewMethodChain(): boolean;
|
|
581
858
|
cloneWithType(match: RangerArgMatch, changeVref: boolean): CodeNode;
|
|
582
859
|
rebuildWithType(match: RangerArgMatch, changeVref: boolean): CodeNode;
|
|
@@ -589,6 +866,7 @@ export declare class CodeNode {
|
|
|
589
866
|
typeNameAsType(ctx: RangerAppWriterContext): number;
|
|
590
867
|
copyEvalResFrom(node: CodeNode): void;
|
|
591
868
|
defineNodeTypeTo(node: CodeNode, ctx: RangerAppWriterContext): void;
|
|
869
|
+
defineNodeTypeToSelf(ctx: RangerAppWriterContext): void;
|
|
592
870
|
ifNoTypeSetToVoid(): void;
|
|
593
871
|
ifNoTypeSetToEvalTypeOf(node: CodeNode): boolean;
|
|
594
872
|
static vref1(name: string): CodeNode;
|
|
@@ -702,6 +980,10 @@ export declare class RangerAppWriterContext {
|
|
|
702
980
|
targetLangName: string;
|
|
703
981
|
parent?: RangerAppWriterContext;
|
|
704
982
|
defined_imports: Array<string>;
|
|
983
|
+
active_macros: {
|
|
984
|
+
[key: string]: boolean;
|
|
985
|
+
};
|
|
986
|
+
macro_expansion_depth: number;
|
|
705
987
|
already_imported: {
|
|
706
988
|
[key: string]: boolean;
|
|
707
989
|
};
|
|
@@ -839,6 +1121,10 @@ export declare class RangerAppWriterContext {
|
|
|
839
1121
|
[key: string]: number;
|
|
840
1122
|
};
|
|
841
1123
|
rust_temp_counter: number;
|
|
1124
|
+
rust_path_field_names: {
|
|
1125
|
+
[key: string]: boolean;
|
|
1126
|
+
};
|
|
1127
|
+
rust_path_names_ready: boolean;
|
|
842
1128
|
rootFile: string;
|
|
843
1129
|
constructor();
|
|
844
1130
|
rustMarkMoved(varName: string): void;
|
|
@@ -900,7 +1186,10 @@ export declare class RangerAppWriterContext {
|
|
|
900
1186
|
addCapturedVariable(name: string): void;
|
|
901
1187
|
getCapturedVariables(): Array<string>;
|
|
902
1188
|
transformOpNameWord(input_word: string): string;
|
|
1189
|
+
transformMemberWord(input_word: string): string;
|
|
1190
|
+
transformBindingWord(input_word: string): string;
|
|
903
1191
|
transformWord(input_word: string): string;
|
|
1192
|
+
getTargetLangName(): string;
|
|
904
1193
|
initReservedWords(): boolean;
|
|
905
1194
|
initStdCommands(): boolean;
|
|
906
1195
|
transformTypeName(typeName: string): string;
|
|
@@ -917,6 +1206,7 @@ export declare class RangerAppWriterContext {
|
|
|
917
1206
|
canUseTypeInference(nameNode: CodeNode): boolean;
|
|
918
1207
|
createOpStaticClass(name: string): RangerAppClassDesc;
|
|
919
1208
|
createTraitInstanceClass(traitName: string, instanceName: string, initParams: CodeNode, flowParser: RangerFlowParser, wr: CodeWriter): Promise<RangerAppClassDesc> | undefined;
|
|
1209
|
+
createGenericClassInstance(templateName: string, instanceName: string, typeArgs: CodeNode, flowParser: RangerFlowParser, wr: CodeWriter): Promise<RangerAppClassDesc> | undefined;
|
|
920
1210
|
createOperator(fromNode: CodeNode): void;
|
|
921
1211
|
findClassMethod(cname: string, fname: string): RangerAppFunctionDesc | undefined;
|
|
922
1212
|
getFileWriter(path: string, fileName: string): CodeWriter;
|
|
@@ -1025,6 +1315,28 @@ export declare class SourceMapBuilder {
|
|
|
1025
1315
|
toJSON(fileName: string): string;
|
|
1026
1316
|
hasMappings(): boolean;
|
|
1027
1317
|
}
|
|
1318
|
+
export declare class RangerSourceFormat {
|
|
1319
|
+
constructor();
|
|
1320
|
+
static defaultWidthFor(ext: string): number;
|
|
1321
|
+
static dotLeadsLine(ext: string): boolean;
|
|
1322
|
+
static isSpaceCode(c: number): boolean;
|
|
1323
|
+
static indentOf(line: string): string;
|
|
1324
|
+
static isCommentOrEmpty(line: string): boolean;
|
|
1325
|
+
static codeEndOf(line: string): number;
|
|
1326
|
+
static chainSplits(line: string): Array<number>;
|
|
1327
|
+
static breakChainLine(line: string, ext: string): string;
|
|
1328
|
+
static isCallKeyword(word: string): boolean;
|
|
1329
|
+
static isWordCode(c: number): boolean;
|
|
1330
|
+
static wordBefore(line: string, i: number): string;
|
|
1331
|
+
static argListOpen(line: string): number;
|
|
1332
|
+
static topCommaCount(line: string, open: number, limit: number): number;
|
|
1333
|
+
static topCommaAt(line: string, open: number, limit: number): Array<number>;
|
|
1334
|
+
static codeTailChar(line: string): number;
|
|
1335
|
+
static breakArgLine(line: string, ext: string): string;
|
|
1336
|
+
static hasOpenString(line: string): boolean;
|
|
1337
|
+
static breakRustBlockLine(line: string, ext: string): string;
|
|
1338
|
+
static formatSource(text: string, ext: string, width: number): string;
|
|
1339
|
+
}
|
|
1028
1340
|
export declare class CodeFile {
|
|
1029
1341
|
path_name: string;
|
|
1030
1342
|
name: string;
|
|
@@ -1036,7 +1348,7 @@ export declare class CodeFile {
|
|
|
1036
1348
|
fileSystem?: CodeFileSystem;
|
|
1037
1349
|
sourceMapBuilder?: SourceMapBuilder;
|
|
1038
1350
|
constructor(filePath: string, fileName: string);
|
|
1039
|
-
initSourceMapsIfNeeded(): void;
|
|
1351
|
+
initSourceMapsIfNeeded(mapsEnabled: boolean): void;
|
|
1040
1352
|
addImport(import_name: string): void;
|
|
1041
1353
|
rewrite(newString: string): void;
|
|
1042
1354
|
testCreateWriter(): CodeWriter;
|
|
@@ -1047,6 +1359,7 @@ export declare class CodeFile {
|
|
|
1047
1359
|
export declare class CodeFileSystem {
|
|
1048
1360
|
files: Array<CodeFile>;
|
|
1049
1361
|
sourceMapsEnabled: boolean;
|
|
1362
|
+
formatWidth: number;
|
|
1050
1363
|
constructor();
|
|
1051
1364
|
enableSourceMaps(): void;
|
|
1052
1365
|
shouldWriteSourceMaps(): boolean;
|
|
@@ -1063,6 +1376,10 @@ export declare class CodeSlice {
|
|
|
1063
1376
|
}
|
|
1064
1377
|
export declare class CodeWriter {
|
|
1065
1378
|
tagName: string;
|
|
1379
|
+
suppress_expr_parens: boolean;
|
|
1380
|
+
current_op_no_parens: boolean;
|
|
1381
|
+
in_format_args: boolean;
|
|
1382
|
+
parent_binding: number;
|
|
1066
1383
|
codeStr: string;
|
|
1067
1384
|
currentLine: string;
|
|
1068
1385
|
tabStr: string;
|
|
@@ -1123,6 +1440,7 @@ export declare class CodeWriter {
|
|
|
1123
1440
|
}
|
|
1124
1441
|
export declare class RangerLispParser {
|
|
1125
1442
|
code?: SourceCode;
|
|
1443
|
+
source_text: string;
|
|
1126
1444
|
buff?: string;
|
|
1127
1445
|
__len: number;
|
|
1128
1446
|
i: number;
|
|
@@ -1136,23 +1454,34 @@ export declare class RangerLispParser {
|
|
|
1136
1454
|
curr_node?: CodeNode;
|
|
1137
1455
|
had_error: boolean;
|
|
1138
1456
|
disableOperators: boolean;
|
|
1457
|
+
recv_tmp_count: number;
|
|
1458
|
+
last_call_group?: CodeNode;
|
|
1459
|
+
pending_comments: Array<CodeNode>;
|
|
1139
1460
|
constructor(code_module: SourceCode);
|
|
1140
1461
|
joo(cm: SourceCode): void;
|
|
1141
1462
|
parse_raw_annotation(): CodeNode;
|
|
1142
|
-
skip_space(is_block_parent: boolean): boolean;
|
|
1463
|
+
skip_space(s: string, is_block_parent: boolean): boolean;
|
|
1143
1464
|
end_expression(consumeCurrent: boolean): boolean;
|
|
1144
|
-
getOperator(disabled: boolean): number;
|
|
1145
|
-
isOperator(disabled: boolean): number;
|
|
1465
|
+
getOperator(s: string, disabled: boolean): number;
|
|
1466
|
+
isOperator(s: string, disabled: boolean): number;
|
|
1146
1467
|
getOperatorPred(str: string, disabled: boolean): number;
|
|
1147
1468
|
isComparisonOpPred(pred: number): boolean;
|
|
1469
|
+
isFoldableInfixPred(pred: number): boolean;
|
|
1148
1470
|
isDotVRef(n: CodeNode): boolean;
|
|
1149
1471
|
isDotCallPairOnNode(node: CodeNode): boolean;
|
|
1472
|
+
isCallChainOnNode(node: CodeNode): boolean;
|
|
1473
|
+
foldCallChainToGroup(node: CodeNode): void;
|
|
1150
1474
|
foldDotCallPairToGroup(node: CodeNode): void;
|
|
1475
|
+
isPlainDotCallee(n: CodeNode, paren_pos: number): boolean;
|
|
1476
|
+
isChainTailCallee(n: CodeNode, paren_pos: number): boolean;
|
|
1477
|
+
insertCallOrNode(p_node: CodeNode): boolean;
|
|
1151
1478
|
tryCloseCallArgParenBeforeInfix(): boolean;
|
|
1152
1479
|
insert_node(p_node: CodeNode): void;
|
|
1153
|
-
|
|
1154
|
-
|
|
1480
|
+
attachPendingComments(node: CodeNode): void;
|
|
1481
|
+
parse_attributes(s: string): boolean;
|
|
1482
|
+
parseXML(s: string): void;
|
|
1155
1483
|
parse(disable_ops: boolean): void;
|
|
1484
|
+
parseBuf(s: string, disable_ops: boolean): void;
|
|
1156
1485
|
static normalizeLineEndings(src: string): string;
|
|
1157
1486
|
}
|
|
1158
1487
|
export declare class TTypes {
|
|
@@ -1176,6 +1505,7 @@ export declare class RangerArgMatch {
|
|
|
1176
1505
|
matchedLambdas: {
|
|
1177
1506
|
[key: string]: CodeNode;
|
|
1178
1507
|
};
|
|
1508
|
+
typeParamNames: Array<string>;
|
|
1179
1509
|
constructor();
|
|
1180
1510
|
matchArguments(args: CodeNode, callArgs: CodeNode, ctx: RangerAppWriterContext, firstArgIndex: number): boolean;
|
|
1181
1511
|
force_add(tplKeyword: string, typeName: string, ctx: RangerAppWriterContext): void;
|
|
@@ -1186,6 +1516,9 @@ export declare class RangerArgMatch {
|
|
|
1186
1516
|
doesMatch(arg: CodeNode, node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1187
1517
|
areEqualTypes(type1o: string, type2o: string, ctx: RangerAppWriterContext): boolean;
|
|
1188
1518
|
areEqualATypes(type1i: string, type2i: string, ctx: RangerAppWriterContext): boolean;
|
|
1519
|
+
addTypeParam(tplKeyword: string, typeName: string): boolean;
|
|
1520
|
+
isCollectionParam(n: string): boolean;
|
|
1521
|
+
applyCollectionType(node: CodeNode, n: string): void;
|
|
1189
1522
|
getTypeName(n: string): string;
|
|
1190
1523
|
getType(n: string): number;
|
|
1191
1524
|
setRvBasedOn(arg: CodeNode, node: CodeNode): boolean;
|
|
@@ -1322,6 +1655,53 @@ export declare class TFiles {
|
|
|
1322
1655
|
static searchEnv(env: InputEnv, paths: Array<string>, fileName: string): string;
|
|
1323
1656
|
static search(paths: Array<string>, fileName: string): string;
|
|
1324
1657
|
}
|
|
1658
|
+
export declare class PkgHit {
|
|
1659
|
+
ok: boolean;
|
|
1660
|
+
err: string;
|
|
1661
|
+
dir: string;
|
|
1662
|
+
name: string;
|
|
1663
|
+
packageId: string;
|
|
1664
|
+
constructor();
|
|
1665
|
+
}
|
|
1666
|
+
export declare class PkgJVal {
|
|
1667
|
+
kind: string;
|
|
1668
|
+
str: string;
|
|
1669
|
+
keys: Array<string>;
|
|
1670
|
+
vals: Array<PkgJVal>;
|
|
1671
|
+
constructor();
|
|
1672
|
+
}
|
|
1673
|
+
export declare class PkgJRead {
|
|
1674
|
+
text: string;
|
|
1675
|
+
i: number;
|
|
1676
|
+
n: number;
|
|
1677
|
+
ok: boolean;
|
|
1678
|
+
constructor();
|
|
1679
|
+
parse(src: string): PkgJVal;
|
|
1680
|
+
skipWs(): void;
|
|
1681
|
+
val(): PkgJVal;
|
|
1682
|
+
obj(): PkgJVal;
|
|
1683
|
+
quoted(): string;
|
|
1684
|
+
static child(obj: PkgJVal, key: string): PkgJVal | undefined;
|
|
1685
|
+
static strOf(obj: PkgJVal, key: string): string;
|
|
1686
|
+
}
|
|
1687
|
+
export declare class PkgImport {
|
|
1688
|
+
constructor();
|
|
1689
|
+
static isPkg(spec: string): boolean;
|
|
1690
|
+
static stripDot(spec: string): string;
|
|
1691
|
+
static cacheRoot(): string;
|
|
1692
|
+
static joinPath(a: string, b: string): string;
|
|
1693
|
+
static foldPath(path: string): string;
|
|
1694
|
+
static splitName(path: string): Array<string>;
|
|
1695
|
+
static parentDir(dir: string): string;
|
|
1696
|
+
static findManifestDir(env: InputEnv, start: string, paths: Array<string>): string;
|
|
1697
|
+
static walkUp(env: InputEnv, start: string): string;
|
|
1698
|
+
static readText(env: InputEnv, dir: string, name: string): Promise<string>;
|
|
1699
|
+
static findChar(s: string, code: number): number;
|
|
1700
|
+
static manifestChain(env: InputEnv, startDir: string, libraryPaths: Array<string>): Array<string>;
|
|
1701
|
+
static resolve(env: InputEnv, startDir: string, spec: string, libraryPaths: Array<string>): Promise<PkgHit>;
|
|
1702
|
+
static resolveIn(env: InputEnv, manDir: string, spec: string): Promise<PkgHit>;
|
|
1703
|
+
static lockRoot(env: InputEnv, lockText: string, pkgName: string, manDir: string): string;
|
|
1704
|
+
}
|
|
1325
1705
|
export declare class ClassJoinPoint {
|
|
1326
1706
|
class_def?: RangerAppClassDesc;
|
|
1327
1707
|
node?: CodeNode;
|
|
@@ -1332,10 +1712,82 @@ export declare class WalkLater {
|
|
|
1332
1712
|
callArg?: CodeNode;
|
|
1333
1713
|
constructor();
|
|
1334
1714
|
}
|
|
1715
|
+
export declare class RangerFnParts {
|
|
1716
|
+
ok: boolean;
|
|
1717
|
+
nameNode?: CodeNode;
|
|
1718
|
+
fnArgs?: CodeNode;
|
|
1719
|
+
fnBody?: CodeNode;
|
|
1720
|
+
desc?: RangerAppClassDesc;
|
|
1721
|
+
constructor();
|
|
1722
|
+
}
|
|
1335
1723
|
export declare class RangerFlowParser {
|
|
1336
1724
|
hasRootPath: boolean;
|
|
1337
1725
|
rootPath: string;
|
|
1338
1726
|
_debug: boolean;
|
|
1727
|
+
treeChildCall: {
|
|
1728
|
+
[key: string]: string;
|
|
1729
|
+
};
|
|
1730
|
+
treeTextField: {
|
|
1731
|
+
[key: string]: string;
|
|
1732
|
+
};
|
|
1733
|
+
treeTags: {
|
|
1734
|
+
[key: string]: string;
|
|
1735
|
+
};
|
|
1736
|
+
treeTagDefaults: {
|
|
1737
|
+
[key: string]: CodeNode;
|
|
1738
|
+
};
|
|
1739
|
+
treeFactoryNames: {
|
|
1740
|
+
[key: string]: boolean;
|
|
1741
|
+
};
|
|
1742
|
+
treeTmpCount: number;
|
|
1743
|
+
shapeCases: {
|
|
1744
|
+
[key: string]: Array<string>;
|
|
1745
|
+
};
|
|
1746
|
+
shapeGroupCases: {
|
|
1747
|
+
[key: string]: Array<string>;
|
|
1748
|
+
};
|
|
1749
|
+
caseAlias: {
|
|
1750
|
+
[key: string]: string;
|
|
1751
|
+
};
|
|
1752
|
+
groupAlias: {
|
|
1753
|
+
[key: string]: string;
|
|
1754
|
+
};
|
|
1755
|
+
caseShape: {
|
|
1756
|
+
[key: string]: string;
|
|
1757
|
+
};
|
|
1758
|
+
caseDisplay: {
|
|
1759
|
+
[key: string]: string;
|
|
1760
|
+
};
|
|
1761
|
+
caseIsValue: {
|
|
1762
|
+
[key: string]: boolean;
|
|
1763
|
+
};
|
|
1764
|
+
caseFieldNames: {
|
|
1765
|
+
[key: string]: Array<string>;
|
|
1766
|
+
};
|
|
1767
|
+
shapeViews: {
|
|
1768
|
+
[key: string]: ShapeViewDesc;
|
|
1769
|
+
};
|
|
1770
|
+
shapeGroupParent: {
|
|
1771
|
+
[key: string]: string;
|
|
1772
|
+
};
|
|
1773
|
+
shapeGroupFields: {
|
|
1774
|
+
[key: string]: Array<string>;
|
|
1775
|
+
};
|
|
1776
|
+
shapeGroupFieldTypeName: {
|
|
1777
|
+
[key: string]: string;
|
|
1778
|
+
};
|
|
1779
|
+
shapeGroupFieldArrayType: {
|
|
1780
|
+
[key: string]: string;
|
|
1781
|
+
};
|
|
1782
|
+
shapeGroupFieldKeyType: {
|
|
1783
|
+
[key: string]: string;
|
|
1784
|
+
};
|
|
1785
|
+
shapeGroupAllValue: {
|
|
1786
|
+
[key: string]: boolean;
|
|
1787
|
+
};
|
|
1788
|
+
shapeCaseCtorArgs: {
|
|
1789
|
+
[key: string]: string;
|
|
1790
|
+
};
|
|
1339
1791
|
stdCommands?: CodeNode;
|
|
1340
1792
|
lastProcessedNode?: CodeNode;
|
|
1341
1793
|
collectWalkAtEnd: Array<CodeNode>;
|
|
@@ -1361,6 +1813,7 @@ export declare class RangerFlowParser {
|
|
|
1361
1813
|
[key: string]: string;
|
|
1362
1814
|
};
|
|
1363
1815
|
allNewRNodes: Array<CodeNode>;
|
|
1816
|
+
inline_static_depth: number;
|
|
1364
1817
|
infinite_recursion: boolean;
|
|
1365
1818
|
match_types: {
|
|
1366
1819
|
[key: string]: string;
|
|
@@ -1375,7 +1828,7 @@ export declare class RangerFlowParser {
|
|
|
1375
1828
|
getThisName(): string;
|
|
1376
1829
|
GetProperty(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1377
1830
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1378
|
-
|
|
1831
|
+
EnterFnParts(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<RangerFnParts>;
|
|
1379
1832
|
Constructor(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1380
1833
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1381
1834
|
normalizeNewArgList(node: CodeNode): void;
|
|
@@ -1384,6 +1837,10 @@ export declare class RangerFlowParser {
|
|
|
1384
1837
|
transformParams2(list: Array<CodeNode>, fnArgs: Array<CodeNode>, ctx: RangerAppWriterContext): Array<CodeNode>;
|
|
1385
1838
|
CreateCTTI(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
1386
1839
|
CreateRTTI(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
1840
|
+
walkXmlCreate(xmlNode: CodeNode, regName: string, in_currCnt: number, opBody: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<number>;
|
|
1841
|
+
markAsyncFrom(f: RangerAppFunctionDesc, visited: Array<RangerAppFunctionDesc>): Promise<void>;
|
|
1842
|
+
markAsyncFromVariant(f: RangerAppFunctionDesc, visited: Array<RangerAppFunctionDesc>, ctx: RangerAppWriterContext): Promise<void>;
|
|
1843
|
+
markCalledFromMain(f: RangerAppFunctionDesc, ctx: RangerAppWriterContext): Promise<void>;
|
|
1387
1844
|
SolveAsyncFuncs(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1388
1845
|
matchMethodCall(cl: RangerAppClassDesc, methodName: string, callArgs: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter, errNode: CodeNode): Promise<RangerAppFunctionDesc> | undefined;
|
|
1389
1846
|
cmdCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
@@ -1407,9 +1864,15 @@ export declare class RangerFlowParser {
|
|
|
1407
1864
|
testCompile(opFn: CodeNode, node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<{
|
|
1408
1865
|
[key: string]: CodeNode;
|
|
1409
1866
|
}>;
|
|
1867
|
+
inlineStaticEligible(m: RangerAppFunctionDesc, fnNode: CodeNode, ctx: RangerAppWriterContext): Promise<boolean>;
|
|
1868
|
+
tryInlineTrivialStatic(node: CodeNode, fnNode: CodeNode, m: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
1410
1869
|
TransformOpFn(opFnList: Array<CodeNode>, origNode: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1411
1870
|
cmdArray(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1412
1871
|
EnterLambdaMethod(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1872
|
+
annotationIsTypeArgs(tAnn: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1873
|
+
normalizeTypeArg(ch: CodeNode): void;
|
|
1874
|
+
genericInstanceName(baseName: string, tAnn: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<string>;
|
|
1875
|
+
typeArgKey(spelling: string): string;
|
|
1413
1876
|
CheckVRefTypeAnnotationOf(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
1414
1877
|
CheckTypeAnnotationOf(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
1415
1878
|
matchNode(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
@@ -1422,7 +1885,75 @@ export declare class RangerFlowParser {
|
|
|
1422
1885
|
finalizeRecordClasses(ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1423
1886
|
expandRecordCtorArgsIfNeeded(cl: RangerAppClassDesc, fnDescr: RangerAppFunctionDesc, params: CodeNode, node: CodeNode): void;
|
|
1424
1887
|
buildRecordConstructor(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1888
|
+
prepareImport(ctx: RangerAppWriterContext, spec: string): Promise<PkgHit>;
|
|
1425
1889
|
mergeImports(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1890
|
+
DesugarTrees(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1891
|
+
reportStrayTrees(node: CodeNode, ctx: RangerAppWriterContext): void;
|
|
1892
|
+
isTreeFactoryDeclaration(node: CodeNode): boolean;
|
|
1893
|
+
collectTreeFactories(node: CodeNode, atTopLevel: boolean, ctx: RangerAppWriterContext): void;
|
|
1894
|
+
registerTreeFactory(node: CodeNode, ctx: RangerAppWriterContext): void;
|
|
1895
|
+
isTreeLiteral(node: CodeNode): boolean;
|
|
1896
|
+
expandTreesIn(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1897
|
+
expandTreesInBlock(block: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1898
|
+
lowerTreesIn(node: CodeNode, prelude: Array<CodeNode>, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1899
|
+
rewriteAsVRef(node: CodeNode, name: string): void;
|
|
1900
|
+
lowerTreeElement(el: CodeNode, fname: string, prelude: Array<CodeNode>, ctx: RangerAppWriterContext, wr: CodeWriter): string;
|
|
1901
|
+
isTreeKeyword(node: CodeNode, word: string): boolean;
|
|
1902
|
+
lowerComputedChildren(ch: CodeNode, reg: string, fname: string, prelude: Array<CodeNode>, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1903
|
+
treeCall(at_node: CodeNode, reg: string, method: string, arg: CodeNode): CodeNode;
|
|
1904
|
+
lowerTreeProps(propsNode: CodeNode, reg: string, prelude: Array<CodeNode>, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1905
|
+
treeAssign(at_node: CodeNode, reg: string, field: string, value: CodeNode): CodeNode;
|
|
1906
|
+
lowerTreeChild(ch: CodeNode, reg: string, fname: string, prelude: Array<CodeNode>, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1907
|
+
DesugarShapes(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1908
|
+
isShapeDeclaration(node: CodeNode): boolean;
|
|
1909
|
+
expandShapesIn(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter, renames: {
|
|
1910
|
+
[key: string]: string;
|
|
1911
|
+
}): void;
|
|
1912
|
+
expandShapesInScope(node: CodeNode, atTopLevel: boolean, ctx: RangerAppWriterContext, wr: CodeWriter, renames: {
|
|
1913
|
+
[key: string]: string;
|
|
1914
|
+
}): void;
|
|
1915
|
+
registerShapeAlias(target: {
|
|
1916
|
+
[key: string]: string;
|
|
1917
|
+
}, alias: string, clsName: string): void;
|
|
1918
|
+
shapeFieldIsScalar(fieldNode: CodeNode): boolean;
|
|
1919
|
+
shapeFieldName(fieldNode: CodeNode): string;
|
|
1920
|
+
shapeMemberBlock(st: CodeNode): CodeNode;
|
|
1921
|
+
shapeMemberIsField(st: CodeNode): boolean;
|
|
1922
|
+
shapeMemberIsMethod(st: CodeNode): boolean;
|
|
1923
|
+
shapeMethodHasBody(st: CodeNode): boolean;
|
|
1924
|
+
shapeMethodSignatureKey(mNode: CodeNode): string;
|
|
1925
|
+
rewriteMethodFieldRefs(node: CodeNode, fieldNames: Array<string>, selfName: string): void;
|
|
1926
|
+
findOpsClassBlock(root: CodeNode): CodeNode | undefined;
|
|
1927
|
+
attachOpsMethods(opsRoot: CodeNode, viewName: string, methodNodes: Array<CodeNode>, methodStatic: Array<boolean>, fieldNames: Array<string>, ctx: RangerAppWriterContext): void;
|
|
1928
|
+
attachShapeMethods(eqRoot: CodeNode, shapeName: string, opsName: string, methodNodes: Array<CodeNode>, methodNames: Array<string>, methodStatic: Array<boolean>, ctx: RangerAppWriterContext): void;
|
|
1929
|
+
parseOpsClassRoot(src: string, filename: string, shapeNode: CodeNode, ctx: RangerAppWriterContext): CodeNode | undefined;
|
|
1930
|
+
registerShapeView(shapeName: string, viewKind: string, viewName: string, className: string, allowed: Array<string>, parentView: string): void;
|
|
1931
|
+
shapeTypeSpelling(typeName: string, arrayType: string, keyType: string): string;
|
|
1932
|
+
shapeGroupHasField(groupCls: string, fieldName: string): boolean;
|
|
1933
|
+
buildGroupFieldAccessorSrc(shapeName: string, gn: string, gClsName: string, mems: Array<string>, fieldNames: Array<string>, allowSet: boolean): string;
|
|
1934
|
+
rewriteToGroupFieldGet(node: CodeNode, receiver: CodeNode, fieldName: string, groupCls: string, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1935
|
+
rewriteToGroupWiden(node: CodeNode, targetGroupCls: string, sourceGroupCls: string, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1936
|
+
expandShape(shapeNode: CodeNode, parent: CodeNode, shapeIndex: number, ctx: RangerAppWriterContext, wr: CodeWriter, renames: {
|
|
1937
|
+
[key: string]: string;
|
|
1938
|
+
}): void;
|
|
1939
|
+
isMatchStatement(node: CodeNode): boolean;
|
|
1940
|
+
expandMatchesIn(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1941
|
+
expandMatchesInFn(node: CodeNode, enclosing: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1942
|
+
expandGroupKindTests(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1943
|
+
buildCaseKindTest(proto: CodeNode, scrutinee: CodeNode, cls: string): CodeNode;
|
|
1944
|
+
declaredTypeOf(fnNode: CodeNode, name: string): string;
|
|
1945
|
+
declaredTypeInBody(node: CodeNode, name: string): string;
|
|
1946
|
+
matchArmCases(armName: string, node: CodeNode, ctx: RangerAppWriterContext): Array<string>;
|
|
1947
|
+
expandMatch(matchNode: CodeNode, parent: CodeNode, matchIndex: number, enclosing: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1948
|
+
setShapeRef(node: CodeNode, replacement: string): void;
|
|
1949
|
+
rewriteShapeRefs(node: CodeNode, renames: {
|
|
1950
|
+
[key: string]: string;
|
|
1951
|
+
}): void;
|
|
1952
|
+
isClassMemberForm(node: CodeNode): boolean;
|
|
1953
|
+
markParentClass(ee: CodeNode, childName: string, ctx: RangerAppWriterContext): void;
|
|
1954
|
+
WalkCollectTemplates(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1955
|
+
isDocumentableHead(name: string): boolean;
|
|
1956
|
+
DetachDocBlocks(node: CodeNode, ctx: RangerAppWriterContext): void;
|
|
1426
1957
|
CollectMethods(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1427
1958
|
defineFunctionParam(method: RangerAppFunctionDesc, arg: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1428
1959
|
spliceFunctionBody(startIndex: number, node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): CodeNode;
|
|
@@ -1442,6 +1973,7 @@ export declare class RangerFlowParser {
|
|
|
1442
1973
|
resolveProcessPathFromFields(cl: RangerAppClassDesc): void;
|
|
1443
1974
|
validateProcessPaths(processClasses: Array<RangerAppClassDesc>, ctx: RangerAppWriterContext): void;
|
|
1444
1975
|
isValidProcessPath(pathStr: string): boolean;
|
|
1976
|
+
isJustVref(a: CodeNode): boolean;
|
|
1445
1977
|
findLanguageOper(details: CodeNode, ctx: RangerAppWriterContext, opDef: CodeNode): Promise<CodeNode> | undefined;
|
|
1446
1978
|
buildMacro(langOper: CodeNode, args: CodeNode, ctx: RangerAppWriterContext): Promise<CodeNode>;
|
|
1447
1979
|
operandIsNonOptionalForNullCheck(node: CodeNode): boolean;
|
|
@@ -1493,19 +2025,41 @@ export declare class RangerGenericClassWriter {
|
|
|
1493
2025
|
compFlags: {
|
|
1494
2026
|
[key: string]: boolean;
|
|
1495
2027
|
};
|
|
2028
|
+
fmtMode: number;
|
|
1496
2029
|
constructor();
|
|
2030
|
+
bindingPowerOf(opName: string): number;
|
|
2031
|
+
operandNeedsParens(childBp: number, parentBp: number): boolean;
|
|
2032
|
+
formatterEnabled(ctx: RangerAppWriterContext): boolean;
|
|
2033
|
+
isIdentStartChar(c: number): boolean;
|
|
2034
|
+
isPostfixTopChar(s: string, i: number, c: number, n: number): boolean;
|
|
2035
|
+
isPostfixExpression(s: string): boolean;
|
|
2036
|
+
isWrappedInParens(s: string): boolean;
|
|
2037
|
+
receiverNeedsParens(s: string): boolean;
|
|
2038
|
+
writeCallReceiver(obj: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2039
|
+
unionIsSealable(ucl: RangerAppClassDesc, ctx: RangerAppWriterContext): boolean;
|
|
2040
|
+
unionInterfaceName(unionName: string): string;
|
|
2041
|
+
sealableUnionNames(ctx: RangerAppWriterContext): Array<string>;
|
|
2042
|
+
unionInterfacesOf(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): Array<string>;
|
|
2043
|
+
classInSealableUnion(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): boolean;
|
|
2044
|
+
sealableUnionTypeOr(unionName: string, topType: string, ctx: RangerAppWriterContext): string;
|
|
1497
2045
|
lineEnding(): string;
|
|
2046
|
+
opWritesOwnParens(opName: string, node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1498
2047
|
addSystemImport(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1499
2048
|
EncodeString(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): string;
|
|
1500
2049
|
CustomOperator(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2050
|
+
beforeOperatorStatement(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1501
2051
|
WriteSetterVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1502
2052
|
writeArrayTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1503
2053
|
WriteEnum(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2054
|
+
doubleNeedsPointZero(dd_str: string): boolean;
|
|
1504
2055
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1505
2056
|
getTypeString(type_string: string): string;
|
|
2057
|
+
emptyBlockFiller(): string;
|
|
1506
2058
|
import_lib(lib_name: string, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1507
2059
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1508
2060
|
release_local_vars(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2061
|
+
renderDocExample(fd: RangerAppFunctionDesc, ctx: RangerAppWriterContext, outer: CodeWriter): Promise<string>;
|
|
2062
|
+
trimTrailingBlank(text: string): string;
|
|
1509
2063
|
WalkNode(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1510
2064
|
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1511
2065
|
writeRawTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -1572,7 +2126,13 @@ export declare class RangerJava7ClassWriter extends RangerGenericClassWriter {
|
|
|
1572
2126
|
export declare class RangerSwift3ClassWriter extends RangerGenericClassWriter {
|
|
1573
2127
|
compiler?: LiveCompiler;
|
|
1574
2128
|
header_created: boolean;
|
|
2129
|
+
swift_unions_written: boolean;
|
|
1575
2130
|
constructor();
|
|
2131
|
+
writeSwiftUnionEnums(ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2132
|
+
swiftDeclaredClassOf(nVal: CodeNode): string;
|
|
2133
|
+
swiftUnionHasMember(ucl: RangerAppClassDesc, memberName: string): boolean;
|
|
2134
|
+
swiftWriteUnionValue(targetTypeName: string, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2135
|
+
swiftWriteUnionArg(arg: RangerAppParamDesc, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
1576
2136
|
adjustType(tn: string): string;
|
|
1577
2137
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1578
2138
|
getTypeString(type_string: string): string;
|
|
@@ -1587,6 +2147,7 @@ export declare class RangerSwift3ClassWriter extends RangerGenericClassWriter {
|
|
|
1587
2147
|
CreateLambdaCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1588
2148
|
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1589
2149
|
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2150
|
+
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1590
2151
|
haveSameSig(fn1: RangerAppFunctionDesc, fn2: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
1591
2152
|
CustomOperator(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1592
2153
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -1594,8 +2155,20 @@ export declare class RangerSwift3ClassWriter extends RangerGenericClassWriter {
|
|
|
1594
2155
|
export declare class RangerSwift6ClassWriter extends RangerGenericClassWriter {
|
|
1595
2156
|
compiler?: LiveCompiler;
|
|
1596
2157
|
header_created: boolean;
|
|
2158
|
+
swift_unions_written: boolean;
|
|
1597
2159
|
constructor();
|
|
1598
2160
|
adjustType(tn: string): string;
|
|
2161
|
+
isSwiftValueTypeOf(t: number): boolean;
|
|
2162
|
+
isSwiftValueCollection(nn: CodeNode): boolean;
|
|
2163
|
+
isSwiftValueType(nn: CodeNode): boolean;
|
|
2164
|
+
paramNeedsLocalCopy(arg: RangerAppParamDesc): boolean;
|
|
2165
|
+
swiftWriteMutableParamCopies(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2166
|
+
paramNeedsInout(arg: RangerAppParamDesc): boolean;
|
|
2167
|
+
writeSwiftUnionEnums(ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2168
|
+
swiftDeclaredClassOf(nVal: CodeNode): string;
|
|
2169
|
+
swiftUnionHasMember(ucl: RangerAppClassDesc, memberName: string): boolean;
|
|
2170
|
+
swiftWriteUnionValue(targetTypeName: string, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2171
|
+
swiftWriteUnionArg(arg: RangerAppParamDesc, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
1599
2172
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1600
2173
|
collectionTypeStringToSwift(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1601
2174
|
getTypeString(type_string: string): string;
|
|
@@ -1607,11 +2180,15 @@ export declare class RangerSwift6ClassWriter extends RangerGenericClassWriter {
|
|
|
1607
2180
|
writeArgsDefWithLocals(fnDesc: RangerAppFunctionDesc, localFnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1608
2181
|
resolveCallReceiverClassName(obj: CodeNode, ctx: RangerAppWriterContext): string;
|
|
1609
2182
|
isSimpleClassCallReceiver(obj: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2183
|
+
receiverIsNullable(obj: CodeNode): boolean;
|
|
2184
|
+
callResultIsDiscarded(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2185
|
+
writeSideEffectOnlyStmt(value: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1610
2186
|
CreateCallExpression(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1611
2187
|
writeFnCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1612
2188
|
CreateLambdaCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1613
2189
|
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1614
2190
|
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2191
|
+
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1615
2192
|
haveSameSig(fn1: RangerAppFunctionDesc, fn2: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
1616
2193
|
CustomOperator(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1617
2194
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -1623,12 +2200,21 @@ export declare class RangerCppClassWriter extends RangerGenericClassWriter {
|
|
|
1623
2200
|
header_created: boolean;
|
|
1624
2201
|
buf_ret_seen: boolean;
|
|
1625
2202
|
buf_ret_all_safe: boolean;
|
|
2203
|
+
cpp_single_thread: boolean;
|
|
1626
2204
|
constructor();
|
|
2205
|
+
cppPtr(inner: string): string;
|
|
2206
|
+
cppPtrOpen(): string;
|
|
2207
|
+
cppMakeOpen(): string;
|
|
2208
|
+
cppEsft(inner: string): string;
|
|
2209
|
+
readCppPtrFlag(ctx: RangerAppWriterContext): void;
|
|
2210
|
+
writeCppSingleThreadPrelude(wr: CodeWriter): void;
|
|
1627
2211
|
lineEnding(): string;
|
|
1628
2212
|
adjustType(tn: string): string;
|
|
2213
|
+
escapeCppTrigraphs(s: string): string;
|
|
1629
2214
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1630
2215
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1631
2216
|
collectionTypeStringToCpp(type_string: string, ctx: RangerAppWriterContext): string;
|
|
2217
|
+
cppUnionValueCase(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): boolean;
|
|
1632
2218
|
getTypeString2(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1633
2219
|
writePtr(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1634
2220
|
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -1637,21 +2223,33 @@ export declare class RangerCppClassWriter extends RangerGenericClassWriter {
|
|
|
1637
2223
|
cppScanBufferReturns(node: CodeNode): void;
|
|
1638
2224
|
cppBufferReturnByRef(variant: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
1639
2225
|
writeReturnTypeDef(variant: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2226
|
+
cppSegmentIsValueCase(node: CodeNode, idx: number, ctx: RangerAppWriterContext): boolean;
|
|
1640
2227
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1641
2228
|
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1642
2229
|
disabledVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1643
2230
|
CreateCallExpression(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2231
|
+
cppWriteCmpOperand(o: CodeNode, otherIsLiteral: boolean, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1644
2232
|
CustomOperator(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1645
2233
|
CreateMethodCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1646
2234
|
CreatePropertyGet(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1647
2235
|
CreateLambdaCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1648
2236
|
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2237
|
+
cppIsWeakField(nn: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2238
|
+
cppProgramHasWeakField(ctx: RangerAppWriterContext): boolean;
|
|
2239
|
+
writeCppWeakHelper(wr: CodeWriter): void;
|
|
1649
2240
|
writeCppHeaderVar(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter, do_initialize: boolean): Promise<void>;
|
|
1650
2241
|
cppReadonlyValueParam(arg: RangerAppParamDesc): boolean;
|
|
2242
|
+
cppReadonlyUnionParam(arg: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
2243
|
+
cppBorrowedObjectParam(fnDesc: RangerAppFunctionDesc, arg: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
2244
|
+
cppNeedsCallTempCopy(fnDesc: RangerAppFunctionDesc, arg: RangerAppParamDesc, n: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1651
2245
|
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2246
|
+
cppCaptureByReference(vD: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
2247
|
+
cppMutableRefParam(fnDesc: RangerAppFunctionDesc, arg: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
1652
2248
|
writeFnCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1653
2249
|
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1654
2250
|
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2251
|
+
cppUsesThisValue(body: CodeNode): Promise<boolean>;
|
|
2252
|
+
cppNeedsSharedFromThis(node: CodeNode): Promise<boolean>;
|
|
1655
2253
|
writeClassHeader(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1656
2254
|
CreateUnions(parser: RangerFlowParser, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1657
2255
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
@@ -1662,27 +2260,145 @@ export declare class MethodCallList {
|
|
|
1662
2260
|
add(methodName: string): void;
|
|
1663
2261
|
}
|
|
1664
2262
|
export declare class RangerRustClassWriter extends RangerGenericClassWriter {
|
|
2263
|
+
rust_writing_call_receiver: boolean;
|
|
2264
|
+
rust_call_receiver_mut: boolean;
|
|
2265
|
+
rust_receiver_written: boolean;
|
|
2266
|
+
rust_in_trait_decl: boolean;
|
|
2267
|
+
rust_in_weak_unwrap: boolean;
|
|
2268
|
+
rust_lhs_is_receiver: boolean;
|
|
2269
|
+
rust_writing_return_type: boolean;
|
|
2270
|
+
rust_receiverless_method: boolean;
|
|
2271
|
+
rust_receiver_mut_known: boolean;
|
|
2272
|
+
rust_emit_class_name: string;
|
|
2273
|
+
rust_receiver_shared_known: boolean;
|
|
2274
|
+
rust_prop_base_state: number;
|
|
2275
|
+
rust_recv_place_mut: boolean;
|
|
2276
|
+
rust_writing_mut_arg: boolean;
|
|
2277
|
+
rust_path_head_mut: boolean;
|
|
2278
|
+
rust_field_call_mut_ready: boolean;
|
|
2279
|
+
rust_writing_field_type: boolean;
|
|
1665
2280
|
compiler?: LiveCompiler;
|
|
1666
2281
|
thisName: string;
|
|
2282
|
+
rustFnReturnsUnion: string;
|
|
2283
|
+
rustFnReturnNameNode?: CodeNode;
|
|
1667
2284
|
fileHeaderWritten: boolean;
|
|
2285
|
+
rust_in_cell_assign: boolean;
|
|
2286
|
+
rust_last_recv_tmp: string;
|
|
2287
|
+
rust_computing_family_mut: boolean;
|
|
1668
2288
|
constructor();
|
|
1669
2289
|
lineEnding(): string;
|
|
1670
2290
|
adjustType(tn: string): string;
|
|
1671
2291
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2292
|
+
rustStaticStrRead(node: CodeNode): boolean;
|
|
2293
|
+
rustWriteStaticStrValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2294
|
+
rustTryBareStrLitArg(nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): boolean;
|
|
2295
|
+
rustArgIsNameRead(nVal: CodeNode): boolean;
|
|
2296
|
+
rustSliceRefRead(node: CodeNode): boolean;
|
|
2297
|
+
rustStrRefRead(node: CodeNode): boolean;
|
|
2298
|
+
rustLhsHoldsRc(left: CodeNode): boolean;
|
|
2299
|
+
rustValueIsBorrowedHandle(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2300
|
+
CreateLambdaCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2301
|
+
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2302
|
+
writeRustLambdaType(expression_value: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2303
|
+
rustTraitCoerceName(targetType: string, value: CodeNode, ctx: RangerAppWriterContext): string;
|
|
2304
|
+
rustArgValueTypeName(nVal: CodeNode): string;
|
|
2305
|
+
rustNodeCollectionElemType(coll: CodeNode): string;
|
|
2306
|
+
rustSelfRcTraitName(ctx: RangerAppWriterContext): string;
|
|
2307
|
+
rustTypeIsOwnHandle(type_name: string, ctx: RangerAppWriterContext): boolean;
|
|
2308
|
+
rustSharedTypeString(type_name: string, ctx: RangerAppWriterContext): string;
|
|
2309
|
+
rustSharedWeakTypeString(type_name: string, ctx: RangerAppWriterContext): string;
|
|
2310
|
+
rustIsCollectionTypeString(type_string: string): boolean;
|
|
2311
|
+
rustCollectionTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
2312
|
+
rustElementTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1672
2313
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1673
2314
|
getTypeString(type_string: string): string;
|
|
1674
2315
|
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2316
|
+
writeRustWeakVRefTail(node: CodeNode, p: RangerAppParamDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2317
|
+
rustMethodInTraitIface(cl: RangerAppClassDesc, name: string, ctx: RangerAppWriterContext): boolean;
|
|
2318
|
+
rustClassMethodKnownShared(cls: RangerAppClassDesc, name: string, ctx: RangerAppWriterContext): boolean;
|
|
2319
|
+
rustReceiverPathClass(fc: CodeNode, ctx: RangerAppWriterContext): RangerAppClassDesc | undefined;
|
|
2320
|
+
rustReceiverKnownShared(fc: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2321
|
+
rustReceiverKnownMut(node: CodeNode, fc: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2322
|
+
rustReceiverMutFor(node: CodeNode, fc: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2323
|
+
rustThisPrefix(ctx: RangerAppWriterContext): string;
|
|
2324
|
+
rustThisPathPrefix(ctx: RangerAppWriterContext): string;
|
|
1675
2325
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2326
|
+
writeRustFnClose(variant: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2327
|
+
writeRustReturnType(variant: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2328
|
+
rustExprReadsThrough(node: CodeNode, name: string): boolean;
|
|
2329
|
+
rustRhsReadsSharedCell(node: CodeNode): boolean;
|
|
2330
|
+
rustCollectInheritedVars(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, seen: {
|
|
2331
|
+
[key: string]: boolean;
|
|
2332
|
+
}, into: Array<RangerAppParamDesc>): void;
|
|
2333
|
+
rustAllStructVars(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): Array<RangerAppParamDesc>;
|
|
2334
|
+
writeStructFieldType(p: RangerAppParamDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2335
|
+
writeStructFieldTypeInner(p: RangerAppParamDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2336
|
+
rustSegThroughTrait(node: CodeNode, idx: number, ctx: RangerAppWriterContext): boolean;
|
|
1676
2337
|
writeStructField(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2338
|
+
rustFieldAccessorName(p: RangerAppParamDesc): string;
|
|
2339
|
+
rustFieldIsPlainString(p: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
2340
|
+
rustFieldIsCopyScalar(p: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
2341
|
+
writeTraitFieldAccessorDecls(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2342
|
+
writeTraitFieldAccessorImpls(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1677
2343
|
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2344
|
+
rustNewIntoUnion(value: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2345
|
+
rustUnionHasMember(ucl: RangerAppClassDesc, memberName: string): boolean;
|
|
2346
|
+
rustDeclaredClassOf(nVal: CodeNode): string;
|
|
2347
|
+
rustWriteUnionValue(targetTypeName: string, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2348
|
+
rustUnionReturnOf(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): string;
|
|
2349
|
+
rustUnionValueCase(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): boolean;
|
|
2350
|
+
rustArgNeedsUnionWrap(targetTypeName: string, nVal: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2351
|
+
rustWriteUnionArg(arg: RangerAppParamDesc, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2352
|
+
rustClassIsShared(typeName: string, ctx: RangerAppWriterContext): boolean;
|
|
2353
|
+
rustNeedsSelfRc(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
2354
|
+
rustEnclosingMethod(fnDesc: RangerAppFunctionDesc): RangerAppFunctionDesc;
|
|
2355
|
+
rustInitRcState(value: CodeNode, ctx: RangerAppWriterContext): number;
|
|
2356
|
+
rustSelfRcParamType(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): string;
|
|
2357
|
+
rustSelfRcCoerceTo(fc: CodeNode, fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): string;
|
|
2358
|
+
writeSelfRcReceiverArg(node: CodeNode, fc: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): boolean;
|
|
2359
|
+
writeRustReceiver(mutSelf: boolean, wr: CodeWriter): void;
|
|
2360
|
+
writeTraitForwardArgs(variant: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter, lead: boolean): void;
|
|
1678
2361
|
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2362
|
+
rustNodeContainsCall(node: CodeNode): boolean;
|
|
1679
2363
|
containsSelfReference(node: CodeNode): boolean;
|
|
2364
|
+
rustThisSegIsMethod(segName: string, ctx: RangerAppWriterContext): boolean;
|
|
2365
|
+
rustMethodNeedsReceiver(fnD: RangerAppFunctionDesc, body: CodeNode, useCtx: RangerAppWriterContext, ctx: RangerAppWriterContext): boolean;
|
|
2366
|
+
rustBodyGetsOwnClassHandle(node: CodeNode, useCtx: RangerAppWriterContext, ctx: RangerAppWriterContext): boolean;
|
|
2367
|
+
rustBodyGetsClassHandle(node: CodeNode, clsName: string, cl: RangerAppClassDesc): boolean;
|
|
2368
|
+
fnBodyUsesThisStruct(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1680
2369
|
fnBodyUsesThis(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1681
2370
|
accessesFieldOf(node: CodeNode, varName: string): boolean;
|
|
1682
2371
|
getArgRootVar(node: CodeNode): string;
|
|
1683
2372
|
hasMutRefConflict(node: CodeNode, fnDesc: RangerAppFunctionDesc, argIdx: number, givenArgs: CodeNode): boolean;
|
|
1684
2373
|
collectSelfMethodCalls(node: CodeNode, ctx: RangerAppWriterContext, calls: Array<string>): void;
|
|
2374
|
+
rustFieldCallMutatesThis(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2375
|
+
rustFieldPathCallMutates(fcc: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2376
|
+
rustNodeIsOwnPath(nIn: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2377
|
+
rustArgBorrowsThisMutably(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1685
2378
|
fnBodyDirectlyMutatesThis(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2379
|
+
rustCallTargetIsCollection(callObj: CodeNode): boolean;
|
|
2380
|
+
rustIsMutatingOpName(n: string): boolean;
|
|
2381
|
+
buildInheritedMutationGraph(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, directMutations: {
|
|
2382
|
+
[key: string]: boolean;
|
|
2383
|
+
}, callGraph: {
|
|
2384
|
+
[key: string]: MethodCallList;
|
|
2385
|
+
}): void;
|
|
2386
|
+
alignTraitSelfRcNeeds(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): void;
|
|
2387
|
+
rustTraitRootOf(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): RangerAppClassDesc | undefined;
|
|
2388
|
+
rustCallThroughSharedField(callObj: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2389
|
+
rustCollectPathNames(node: CodeNode, ctx: RangerAppWriterContext): void;
|
|
2390
|
+
rustFillPathFieldNames(ctx: RangerAppWriterContext): void;
|
|
2391
|
+
rustFieldCanBeCell(p: RangerAppParamDesc, ctx: RangerAppWriterContext): boolean;
|
|
2392
|
+
rustCellIsString(p: RangerAppParamDesc): boolean;
|
|
2393
|
+
rustCellIsCollection(p: RangerAppParamDesc): boolean;
|
|
2394
|
+
rustCellIsCopy(p: RangerAppParamDesc): boolean;
|
|
2395
|
+
rustCellFieldDesc(node: CodeNode): RangerAppParamDesc | undefined;
|
|
2396
|
+
rustNodeIsCellField(node: CodeNode): boolean;
|
|
2397
|
+
rustMarkInteriorCells(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): void;
|
|
2398
|
+
rustFillTraitMutations(root: RangerAppClassDesc, ctx: RangerAppWriterContext): void;
|
|
2399
|
+
markTraitIfaceMutations(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, directMutations: {
|
|
2400
|
+
[key: string]: boolean;
|
|
2401
|
+
}): void;
|
|
1686
2402
|
buildClassMutationGraph(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, directMutations: {
|
|
1687
2403
|
[key: string]: boolean;
|
|
1688
2404
|
}, callGraph: {
|
|
@@ -1699,46 +2415,134 @@ export declare class RangerRustClassWriter extends RangerGenericClassWriter {
|
|
|
1699
2415
|
[key: string]: MethodCallList;
|
|
1700
2416
|
}): boolean;
|
|
1701
2417
|
fnBodyMutatesThis(node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2418
|
+
rustExprCallNeedsSelfRc(obj: CodeNode, methodName: string, recvIsThis: boolean, ctx: RangerAppWriterContext): boolean;
|
|
1702
2419
|
CreateCallExpression(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2420
|
+
rustBareArgNeedsClone(arg: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
1703
2421
|
CreateMethodCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1704
2422
|
isSelfMethodCall(node: CodeNode): boolean;
|
|
2423
|
+
rustCollectNestedSelfCalls(node: CodeNode, into: Array<CodeNode>): void;
|
|
1705
2424
|
findSelfCallInArgs(node: CodeNode): number;
|
|
1706
2425
|
writeFnCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1707
2426
|
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1708
2427
|
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2428
|
+
writeSingletonAccessor(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1709
2429
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
2430
|
+
rustProgramHasMainFlag(ctx: RangerAppWriterContext): boolean;
|
|
2431
|
+
opWritesOwnParens(opName: string, node: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2432
|
+
rustWriteBitOperand(o: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2433
|
+
rustArgIsAlreadyRef(nVal: CodeNode): boolean;
|
|
2434
|
+
rustArgIsBareThis(nValIn: CodeNode): boolean;
|
|
2435
|
+
rustArgIsPlainMutPath(nValIn: CodeNode): boolean;
|
|
2436
|
+
rustWriteMutArgPrefix(nVal: CodeNode, wr: CodeWriter): void;
|
|
2437
|
+
rustArgIsAlreadyMutRef(nVal: CodeNode): boolean;
|
|
2438
|
+
rustWriteCmpOperand(o: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2439
|
+
rustWriteCastOperandF64(o: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2440
|
+
rustExprIsOptional(inNode: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2441
|
+
rustNodeIsLambda(node: CodeNode): boolean;
|
|
2442
|
+
CreatePropertyGet(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2443
|
+
rustUnwrapParens(node: CodeNode): CodeNode;
|
|
2444
|
+
rustCollectConcatOperands(node: CodeNode, out: Array<CodeNode>): void;
|
|
2445
|
+
rustFmtInline(o: CodeNode): boolean;
|
|
2446
|
+
rustStripToString(o: CodeNode): CodeNode;
|
|
2447
|
+
writeRustFormatOps(ops: Array<CodeNode>, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2448
|
+
rustHoistFieldReceiver(real: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2449
|
+
rustExtractSelfCallConflicts(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2450
|
+
rustTailBorrowsLocal(node: CodeNode): boolean;
|
|
2451
|
+
walkRustFnBody(fnB: CodeNode, sCtx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2452
|
+
rustPlainScalarPath(n: CodeNode): boolean;
|
|
2453
|
+
rustTryCompoundAssign(left: CodeNode, right: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2454
|
+
rustArgNeedsCellWrap(arg: RangerAppParamDesc, nVal: CodeNode, ctx: RangerAppWriterContext): boolean;
|
|
2455
|
+
rustTraitCoerceRoot(right: CodeNode, fieldTypeName: string, ctx: RangerAppWriterContext): string;
|
|
2456
|
+
rustWalkOperand(n: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2457
|
+
rustClassBlocksClone(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, depth: number): boolean;
|
|
2458
|
+
rustIsIndexedWriteOp(n: string): boolean;
|
|
2459
|
+
rustExprMentionsName(node: CodeNode, name: string): boolean;
|
|
2460
|
+
rustArgIsOutParam(node: CodeNode, idx: number): boolean;
|
|
2461
|
+
rustIsSelfCallNode(n: CodeNode): boolean;
|
|
2462
|
+
beforeOperatorStatement(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1710
2463
|
CustomOperator(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1711
2464
|
}
|
|
1712
2465
|
export declare class RangerKotlinClassWriter extends RangerGenericClassWriter {
|
|
1713
2466
|
compiler?: LiveCompiler;
|
|
2467
|
+
kotlin_unions_written: boolean;
|
|
2468
|
+
kotlin_package_written: boolean;
|
|
1714
2469
|
constructor();
|
|
2470
|
+
writeKotlinUnionInterfaces(ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1715
2471
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2472
|
+
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1716
2473
|
adjustType(tn: string): string;
|
|
1717
2474
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1718
2475
|
collectionTypeStringToKotlin(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1719
2476
|
getTypeString(type_string: string): string;
|
|
2477
|
+
writeLambdaType(expression_value: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1720
2478
|
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2479
|
+
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1721
2480
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2481
|
+
EncodeString(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): string;
|
|
2482
|
+
receiverIsNullable(obj: CodeNode): boolean;
|
|
2483
|
+
CreateCallExpression(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2484
|
+
namesStaticMember(cl: RangerAppClassDesc, node: CodeNode): boolean;
|
|
1722
2485
|
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1723
2486
|
paramEmitName(arg: RangerAppParamDesc, ctx: RangerAppWriterContext): string;
|
|
2487
|
+
paramIsMutated(arg: RangerAppParamDesc): boolean;
|
|
2488
|
+
kotlinWriteMutableParamCopies(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1724
2489
|
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1725
2490
|
writeFnCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1726
2491
|
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1727
2492
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
1728
2493
|
}
|
|
2494
|
+
export declare class RangerDartClassWriter extends RangerGenericClassWriter {
|
|
2495
|
+
compiler?: LiveCompiler;
|
|
2496
|
+
wrote_header: boolean;
|
|
2497
|
+
dart_unions_written: boolean;
|
|
2498
|
+
constructor();
|
|
2499
|
+
writeDartUnionInterfaces(ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2500
|
+
EncodeString(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): string;
|
|
2501
|
+
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2502
|
+
adjustType(tn: string): string;
|
|
2503
|
+
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
2504
|
+
collectionTypeStringToDart(type_string: string, ctx: RangerAppWriterContext): string;
|
|
2505
|
+
getTypeString(type_string: string): string;
|
|
2506
|
+
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2507
|
+
namesStaticMember(cl: RangerAppClassDesc, node: CodeNode): boolean;
|
|
2508
|
+
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2509
|
+
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2510
|
+
paramEmitName(arg: RangerAppParamDesc, ctx: RangerAppWriterContext): string;
|
|
2511
|
+
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2512
|
+
receiverIsNullable(obj: CodeNode): boolean;
|
|
2513
|
+
CreateCallExpression(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2514
|
+
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2515
|
+
writeFnCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2516
|
+
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2517
|
+
writePubspec(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
2518
|
+
writeClass(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
2519
|
+
}
|
|
1729
2520
|
export declare class RangerCSharpClassWriter extends RangerGenericClassWriter {
|
|
1730
2521
|
compiler?: LiveCompiler;
|
|
2522
|
+
csharp_unions_written: boolean;
|
|
2523
|
+
csharp_namespace_written: boolean;
|
|
2524
|
+
csLambdaArgCounter: number;
|
|
1731
2525
|
constructor();
|
|
1732
2526
|
adjustType(tn: string): string;
|
|
2527
|
+
writeCSharpUnionInterfaces(ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1733
2528
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
2529
|
+
collectionTypeStringToCS(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1734
2530
|
getTypeString(type_string: string): string;
|
|
1735
2531
|
writeLambdaType(expression_value: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2532
|
+
writeNullableMark(node: CodeNode, wr: CodeWriter): void;
|
|
1736
2533
|
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1737
2534
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2535
|
+
csNodeContainsCall(node: CodeNode): boolean;
|
|
1738
2536
|
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2537
|
+
renameShadowedLambdaArg(arg: CodeNode, ctx: RangerAppWriterContext): void;
|
|
1739
2538
|
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1740
2539
|
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1741
2540
|
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2541
|
+
csCollectInherited(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, vars: {
|
|
2542
|
+
[key: string]: boolean;
|
|
2543
|
+
}, methods: {
|
|
2544
|
+
[key: string]: number;
|
|
2545
|
+
}): void;
|
|
1742
2546
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
1743
2547
|
}
|
|
1744
2548
|
export declare class RangerScalaClassWriter extends RangerGenericClassWriter {
|
|
@@ -1765,9 +2569,18 @@ export declare class RangerGolangClassWriter extends RangerGenericClassWriter {
|
|
|
1765
2569
|
write_raw_type: boolean;
|
|
1766
2570
|
did_write_nullable: boolean;
|
|
1767
2571
|
did_write_sseclient: boolean;
|
|
2572
|
+
go_unions_written: boolean;
|
|
1768
2573
|
httpServerWriter: RangerGolangHttpServerWriter;
|
|
1769
2574
|
constructor();
|
|
2575
|
+
writeGoUnionStructs(ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2576
|
+
goDeclaredClassOf(nVal: CodeNode): string;
|
|
2577
|
+
goUnionHasMember(ucl: RangerAppClassDesc, memberName: string): boolean;
|
|
2578
|
+
goWriteUnionValue(targetTypeName: string, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2579
|
+
goWriteUnionArg(arg: RangerAppParamDesc, nVal: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
1770
2580
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2581
|
+
isCollectionTypeString(type_string: string): boolean;
|
|
2582
|
+
collectionTypeStringToGo(type_string: string, ctx: RangerAppWriterContext): string;
|
|
2583
|
+
goElementTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1771
2584
|
getObjectTypeString(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1772
2585
|
getTypeString2(type_string: string, ctx: RangerAppWriterContext): string;
|
|
1773
2586
|
writeRawTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -1777,16 +2590,19 @@ export declare class RangerGolangClassWriter extends RangerGenericClassWriter {
|
|
|
1777
2590
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1778
2591
|
WriteSetterVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1779
2592
|
goExtractAssign(value: CodeNode, p: RangerAppParamDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2593
|
+
goAncestors(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): Array<string>;
|
|
1780
2594
|
writeStructField(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1781
2595
|
CreateCallExpression(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1782
2596
|
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1783
2597
|
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2598
|
+
writeFnCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1784
2599
|
writeNewCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1785
2600
|
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1786
2601
|
CreateLambdaCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1787
2602
|
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1788
2603
|
CustomOperator(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1789
2604
|
writeInterface(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2605
|
+
writeSingletonAccessor(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1790
2606
|
writeClass(node: CodeNode, ctx: RangerAppWriterContext, orig_wr: CodeWriter): Promise<void>;
|
|
1791
2607
|
}
|
|
1792
2608
|
export declare class RangerGolangHttpServerWriter {
|
|
@@ -1832,17 +2648,30 @@ export declare class RangerPythonClassWriter extends RangerGenericClassWriter {
|
|
|
1832
2648
|
compiler?: LiveCompiler;
|
|
1833
2649
|
thisName: string;
|
|
1834
2650
|
wrote_header: boolean;
|
|
2651
|
+
pyHoistWriters: Array<CodeWriter>;
|
|
2652
|
+
pyLambdaCounter: number;
|
|
1835
2653
|
constructor();
|
|
2654
|
+
emptyBlockFiller(): string;
|
|
1836
2655
|
adjustType(tn: string): string;
|
|
1837
2656
|
EncodeString(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): string;
|
|
1838
2657
|
WriteScalarValue(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1839
2658
|
WriteVRef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2659
|
+
pyNodeContainsCall(node: CodeNode): boolean;
|
|
2660
|
+
pyWalkBody(body: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1840
2661
|
writeVarInitDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1841
2662
|
writeVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1842
2663
|
CreateMethodCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1843
2664
|
CreatePropertyGet(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1844
2665
|
CreateLambdaCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2666
|
+
pyEmittedName(n: CodeNode): string;
|
|
2667
|
+
pyCollectAssigned(node: CodeNode, assigned: {
|
|
2668
|
+
[key: string]: boolean;
|
|
2669
|
+
}, declared: {
|
|
2670
|
+
[key: string]: boolean;
|
|
2671
|
+
}): void;
|
|
1845
2672
|
CreateLambda(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2673
|
+
getPythonTypeName(node: CodeNode, ctx: RangerAppWriterContext): string;
|
|
2674
|
+
writeTypeDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
1846
2675
|
writeClassVarDef(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1847
2676
|
writeArgsDef(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
1848
2677
|
writeArrayLiteral(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -1913,9 +2742,12 @@ export declare class LowIRUtil {
|
|
|
1913
2742
|
constructor();
|
|
1914
2743
|
static typeFromRanger(typeName: string): string;
|
|
1915
2744
|
static isSupportedPrimitive(typeName: string): boolean;
|
|
2745
|
+
static looksLikeUtf8Bytes(text: string): boolean;
|
|
2746
|
+
static utf8Bytes(text: string): Array<number>;
|
|
1916
2747
|
static isStringType(typeName: string): boolean;
|
|
1917
2748
|
static isArrayTypeName(typeName: string): boolean;
|
|
1918
2749
|
static isBufferTypeName(typeName: string): boolean;
|
|
2750
|
+
static isJsonTypeName(typeName: string): boolean;
|
|
1919
2751
|
static isSupportedParam(typeName: string): boolean;
|
|
1920
2752
|
static fieldIrType(typeName: string): string;
|
|
1921
2753
|
static mangleMethod(className: string, methodName: string): string;
|
|
@@ -1969,6 +2801,11 @@ export declare class LowIRField {
|
|
|
1969
2801
|
name: string;
|
|
1970
2802
|
irType: string;
|
|
1971
2803
|
isPtrArray: boolean;
|
|
2804
|
+
isStringMap: boolean;
|
|
2805
|
+
isIntMap: boolean;
|
|
2806
|
+
isIntMapStr: boolean;
|
|
2807
|
+
isStringMapInt: boolean;
|
|
2808
|
+
isStringMapStr: boolean;
|
|
1972
2809
|
isBool: boolean;
|
|
1973
2810
|
isString: boolean;
|
|
1974
2811
|
isBuffer: boolean;
|
|
@@ -2021,6 +2858,8 @@ export declare class LowIRModule {
|
|
|
2021
2858
|
singletonClasses: Array<string>;
|
|
2022
2859
|
lambdaTableFuncs: Array<string>;
|
|
2023
2860
|
lambdaSigs: Array<string>;
|
|
2861
|
+
usesErrorMsg: boolean;
|
|
2862
|
+
bigStackMain: boolean;
|
|
2024
2863
|
constructor();
|
|
2025
2864
|
}
|
|
2026
2865
|
export declare class LowIRSession {
|
|
@@ -2037,33 +2876,40 @@ export declare class LowIRBuilder {
|
|
|
2037
2876
|
blockCounter: number;
|
|
2038
2877
|
blocks: Array<LowIRBlock>;
|
|
2039
2878
|
currentBlock?: LowIRBlock;
|
|
2879
|
+
destTypes: {
|
|
2880
|
+
[key: string]: string;
|
|
2881
|
+
};
|
|
2040
2882
|
constructor(module: LowIRModule);
|
|
2041
2883
|
freshTemp(prefix: string): string;
|
|
2042
2884
|
freshLabel(prefix: string): string;
|
|
2043
2885
|
reset(): void;
|
|
2044
2886
|
startBlock(label: string): string;
|
|
2045
2887
|
emit(instr: LowIRInstr): LowIRInstr;
|
|
2888
|
+
emittedType(value: string): string;
|
|
2046
2889
|
emitToEntry(instr: LowIRInstr): LowIRInstr;
|
|
2047
2890
|
emitConst(irType: string, value: string): string;
|
|
2048
2891
|
emitBin(kind: string, irType: string, lhs: string, rhs: string): string;
|
|
2049
2892
|
emitIcmp(pred: string, lhs: string, rhs: string): string;
|
|
2050
|
-
emitIcmpTyped(pred: string, operandType: string,
|
|
2893
|
+
emitIcmpTyped(pred: string, operandType: string, lhsIn: string, rhsIn: string): string;
|
|
2051
2894
|
emitPtrToInt(ptr: string): string;
|
|
2052
2895
|
emitCall(fnName: string, retType: string, args: Array<string>, argTypes: Array<string>): string;
|
|
2053
2896
|
emitComment(text: string): void;
|
|
2054
|
-
|
|
2897
|
+
coerceCallArgs(args: Array<string>, argTypes: Array<string>): Array<string>;
|
|
2898
|
+
emitCallWithSig(fnName: string, retType: string, callSig: string, rawArgs: Array<string>, argTypes: Array<string>): string;
|
|
2055
2899
|
emitAllocaStruct(className: string, slotName: string, fieldCount: number): string;
|
|
2056
2900
|
emitGep(className: string, structPtr: string, fieldIndex: number): string;
|
|
2057
2901
|
emitAlloca(irType: string, slotName: string): string;
|
|
2058
2902
|
emitZeroInitToEntry(irType: string, slotName: string): void;
|
|
2903
|
+
emitNullInitToEntry(irType: string, slotName: string): void;
|
|
2059
2904
|
emitLoad(irType: string, slotName: string): string;
|
|
2060
|
-
emitStore(irType: string,
|
|
2905
|
+
emitStore(irType: string, valueIn: string, slotName: string): void;
|
|
2061
2906
|
emitHeapAlloc(byteCount: string): string;
|
|
2062
|
-
emitIntToI8Ptr(addr: string,
|
|
2907
|
+
emitIntToI8Ptr(addr: string, addrTypeIn: string): string;
|
|
2063
2908
|
emitIntToStructPtr(className: string, addr: string): string;
|
|
2064
|
-
emitCast(castOp: string, destType: string,
|
|
2909
|
+
emitCast(castOp: string, destType: string, srcTypeIn: string, value: string): string;
|
|
2065
2910
|
emitZextI1ToI32(v: string): string;
|
|
2066
2911
|
emitZextI32ToPtr(v: string): string;
|
|
2912
|
+
addrWidthOf(ptr: string): string;
|
|
2067
2913
|
emitPtrLoad(ptr: string): string;
|
|
2068
2914
|
emitPtrLoadTyped(ptr: string, valueType: string): string;
|
|
2069
2915
|
emitPtrStore(ptr: string, value: string): void;
|
|
@@ -2075,14 +2921,18 @@ export declare class LowIRBuilder {
|
|
|
2075
2921
|
emitGlobalGet(name: string): string;
|
|
2076
2922
|
emitGlobalSet(name: string, value: string): void;
|
|
2077
2923
|
emitFuncRef(name: string): string;
|
|
2078
|
-
emitCallIndirect(retType: string, callSig: string,
|
|
2924
|
+
emitCallIndirect(retType: string, callSig: string, rawArgs: Array<string>, argTypes: Array<string>, selector: string): string;
|
|
2079
2925
|
emitI32At(base: string, byteOff: number): string;
|
|
2080
2926
|
emitStoreI32At(base: string, byteOff: number, value: string): void;
|
|
2927
|
+
emitStoreTypedAt(base: string, byteOff: number, value: string, valueType: string): void;
|
|
2928
|
+
emitLoadTypedAt(base: string, byteOff: number, valueType: string): string;
|
|
2081
2929
|
emitLoadI32At(base: string, byteOff: number): string;
|
|
2082
2930
|
emitStrPtr(globalName: string, byteLen: number): string;
|
|
2083
2931
|
emitTypeDescPtr(className: string): string;
|
|
2084
2932
|
terminateRet(retType: string, value: string): void;
|
|
2085
2933
|
terminateBr(target: string): void;
|
|
2934
|
+
coerceTo(v: string, want: string): string;
|
|
2935
|
+
asI1(v: string): string;
|
|
2086
2936
|
terminateBrIf(cond: string, ifTrue: string, ifFalse: string): void;
|
|
2087
2937
|
terminateUnreachable(): void;
|
|
2088
2938
|
finishFunction(name: string, retType: string, params: Array<LowIRParam>, exportFn: boolean, isMain: boolean): string;
|
|
@@ -2120,6 +2970,7 @@ export declare class LowIRRuntimeGen {
|
|
|
2120
2970
|
static ptrBytes(module: LowIRModule): number;
|
|
2121
2971
|
static descMetaOff(module: LowIRModule): number;
|
|
2122
2972
|
static ensurePtrArrayRuntime(module: LowIRModule): void;
|
|
2973
|
+
static buildRtPtrArrayReserve(module: LowIRModule): void;
|
|
2123
2974
|
static buildRtPtrArrayNew(module: LowIRModule): void;
|
|
2124
2975
|
static buildRtPtrArrayLen(module: LowIRModule): void;
|
|
2125
2976
|
static buildRtPtrArrayGet(module: LowIRModule): void;
|
|
@@ -2151,6 +3002,17 @@ export declare class LowIRLowerContext {
|
|
|
2151
3002
|
slots: {
|
|
2152
3003
|
[key: string]: string;
|
|
2153
3004
|
};
|
|
3005
|
+
paramNames: Array<string>;
|
|
3006
|
+
capturedNames: Array<string>;
|
|
3007
|
+
shadowStack: Array<string>;
|
|
3008
|
+
shadowCounter: number;
|
|
3009
|
+
forceFreshSlots: Array<string>;
|
|
3010
|
+
reslotNames: Array<string>;
|
|
3011
|
+
reslotPrevSlots: Array<string>;
|
|
3012
|
+
reslotPrevTypes: Array<string>;
|
|
3013
|
+
reslotOwnedStr: Array<number>;
|
|
3014
|
+
reslotOwnedObj: Array<number>;
|
|
3015
|
+
reslotOwnedColl: Array<number>;
|
|
2154
3016
|
slotTypes: {
|
|
2155
3017
|
[key: string]: string;
|
|
2156
3018
|
};
|
|
@@ -2163,6 +3025,12 @@ export declare class LowIRLowerContext {
|
|
|
2163
3025
|
ptrArrayElemTypes: {
|
|
2164
3026
|
[key: string]: string;
|
|
2165
3027
|
};
|
|
3028
|
+
smapValueTypes: {
|
|
3029
|
+
[key: string]: string;
|
|
3030
|
+
};
|
|
3031
|
+
imapValueTypes: {
|
|
3032
|
+
[key: string]: string;
|
|
3033
|
+
};
|
|
2166
3034
|
ownedObjectLocals: Array<string>;
|
|
2167
3035
|
ownedCollectionLocals: Array<string>;
|
|
2168
3036
|
ownedStringLocals: Array<string>;
|
|
@@ -2174,6 +3042,9 @@ export declare class LowIRLowerContext {
|
|
|
2174
3042
|
boxedLocals: {
|
|
2175
3043
|
[key: string]: number;
|
|
2176
3044
|
};
|
|
3045
|
+
boxedTypes: {
|
|
3046
|
+
[key: string]: string;
|
|
3047
|
+
};
|
|
2177
3048
|
escapedLocals: {
|
|
2178
3049
|
[key: string]: string;
|
|
2179
3050
|
};
|
|
@@ -2181,6 +3052,12 @@ export declare class LowIRLowerContext {
|
|
|
2181
3052
|
llvmRetType: string;
|
|
2182
3053
|
className: string;
|
|
2183
3054
|
selfPtr: string;
|
|
3055
|
+
breakLabel: string;
|
|
3056
|
+
continueLabel: string;
|
|
3057
|
+
catchLabel: string;
|
|
3058
|
+
loopOwnedMark: number;
|
|
3059
|
+
loopOwnedStrMark: number;
|
|
3060
|
+
loopOwnedCollMark: number;
|
|
2184
3061
|
constructor();
|
|
2185
3062
|
}
|
|
2186
3063
|
export declare class LambdaCaptureInfo {
|
|
@@ -2188,10 +3065,17 @@ export declare class LambdaCaptureInfo {
|
|
|
2188
3065
|
irTypes: Array<string>;
|
|
2189
3066
|
kinds: Array<number>;
|
|
2190
3067
|
objClasses: Array<string>;
|
|
3068
|
+
boxTypes: Array<string>;
|
|
3069
|
+
collKinds: Array<string>;
|
|
3070
|
+
elemTypes: Array<string>;
|
|
3071
|
+
smapValTypes: Array<string>;
|
|
2191
3072
|
offsets: Array<number>;
|
|
2192
3073
|
totalBytes: number;
|
|
2193
3074
|
hasOwned: boolean;
|
|
2194
3075
|
tdName: string;
|
|
3076
|
+
capturesSelf: boolean;
|
|
3077
|
+
selfOffset: number;
|
|
3078
|
+
selfClass: string;
|
|
2195
3079
|
constructor();
|
|
2196
3080
|
}
|
|
2197
3081
|
export declare class LowIRBuilderPass {
|
|
@@ -2200,6 +3084,7 @@ export declare class LowIRBuilderPass {
|
|
|
2200
3084
|
usedArrayRuntime: boolean;
|
|
2201
3085
|
usedPtrArrayRuntime: boolean;
|
|
2202
3086
|
usedMemRuntime: boolean;
|
|
3087
|
+
exprRecvPtr: string;
|
|
2203
3088
|
lambdaSigMap: {
|
|
2204
3089
|
[key: string]: string;
|
|
2205
3090
|
};
|
|
@@ -2207,13 +3092,31 @@ export declare class LowIRBuilderPass {
|
|
|
2207
3092
|
[key: string]: RangerAppFunctionDesc;
|
|
2208
3093
|
};
|
|
2209
3094
|
lambdaNames: Array<string>;
|
|
3095
|
+
lambdaDepths: {
|
|
3096
|
+
[key: string]: number;
|
|
3097
|
+
};
|
|
2210
3098
|
lambdaCounter: number;
|
|
2211
3099
|
lambdaCaptures: {
|
|
2212
3100
|
[key: string]: LambdaCaptureInfo;
|
|
2213
3101
|
};
|
|
3102
|
+
virtualKeys: Array<string>;
|
|
3103
|
+
virtualIsKey: {
|
|
3104
|
+
[key: string]: boolean;
|
|
3105
|
+
};
|
|
3106
|
+
virtualCases: {
|
|
3107
|
+
[key: string]: Array<string>;
|
|
3108
|
+
};
|
|
3109
|
+
virtualImplOf: {
|
|
3110
|
+
[key: string]: string;
|
|
3111
|
+
};
|
|
3112
|
+
virtualDescOf: {
|
|
3113
|
+
[key: string]: RangerAppFunctionDesc;
|
|
3114
|
+
};
|
|
3115
|
+
appRoot?: RangerAppWriterContext;
|
|
2214
3116
|
constructor();
|
|
2215
3117
|
isLambdaTypeNode(node: CodeNode): boolean;
|
|
2216
3118
|
canLowerFunction(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
3119
|
+
isKeywordMarkerParam(p: RangerAppParamDesc): boolean;
|
|
2217
3120
|
canLowerMethod(fnDesc: RangerAppFunctionDesc): boolean;
|
|
2218
3121
|
canLowerInstanceMethod(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
2219
3122
|
isMainEntry(fnDesc: RangerAppFunctionDesc, ctx: RangerAppWriterContext): boolean;
|
|
@@ -2225,11 +3128,14 @@ export declare class LowIRBuilderPass {
|
|
|
2225
3128
|
ensureMemExtern(target: LowIRTarget): void;
|
|
2226
3129
|
memEnabled(lctx: LowIRLowerContext): boolean;
|
|
2227
3130
|
objRcEnabled(lctx: LowIRLowerContext): boolean;
|
|
3131
|
+
strRcEnabled(lctx: LowIRLowerContext): boolean;
|
|
2228
3132
|
wasmStrEnabled(lctx: LowIRLowerContext): boolean;
|
|
2229
3133
|
isLowerableParamType(typeName: string): boolean;
|
|
3134
|
+
isEnumTypeName(typeName: string): boolean;
|
|
2230
3135
|
llvmTypeForRanger(typeName: string, ptrType: string): string;
|
|
2231
3136
|
varTypeName(nameNode: CodeNode): string;
|
|
2232
3137
|
exprIsObjectPtr(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3138
|
+
isRefCountedObjectType(typeName: string): boolean;
|
|
2233
3139
|
isObjectTypeName(typeName: string): boolean;
|
|
2234
3140
|
exprIsString(node: CodeNode): boolean;
|
|
2235
3141
|
exprMightBeString(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
@@ -2260,10 +3166,15 @@ export declare class LowIRBuilderPass {
|
|
|
2260
3166
|
lowerShellArgCnt(lctx: LowIRLowerContext): string;
|
|
2261
3167
|
lowerShellArg(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2262
3168
|
lowerReadFile(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3169
|
+
lowerCreateDir(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3170
|
+
lowerWriteFile(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3171
|
+
lowerNullify(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
2263
3172
|
lowerBufferAlloc(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3173
|
+
emitPtrArrayLenOrBufferLen(bufVal: string, lctx: LowIRLowerContext): string;
|
|
2264
3174
|
lowerBufferLength(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2265
3175
|
lowerBufferGet(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2266
3176
|
lowerBufferSet(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3177
|
+
lowerBufferFill(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2267
3178
|
lowerBufferReadFile(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2268
3179
|
lowerBufferWriteFile(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2269
3180
|
lowerIntBufferAlloc(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
@@ -2272,7 +3183,10 @@ export declare class LowIRBuilderPass {
|
|
|
2272
3183
|
exprIsF64(node: CodeNode): boolean;
|
|
2273
3184
|
promoteToF64(node: CodeNode, val: string, lctx: LowIRLowerContext): string;
|
|
2274
3185
|
lowerToDouble(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3186
|
+
emitDoubleToString(value: string, lctx: LowIRLowerContext): string;
|
|
3187
|
+
emitLibmCall(fnName: string, value: string, lctx: LowIRLowerContext): string;
|
|
2275
3188
|
lowerToInt(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3189
|
+
lowerFloor(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2276
3190
|
lowerStr2Double(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2277
3191
|
lowerStr2Int(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2278
3192
|
lowerIntBufferFill(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
@@ -2284,19 +3198,89 @@ export declare class LowIRBuilderPass {
|
|
|
2284
3198
|
lowerPtrIsNull(ptr: string, lctx: LowIRLowerContext): string;
|
|
2285
3199
|
lowerPtrIsNotNull(ptr: string, lctx: LowIRLowerContext): string;
|
|
2286
3200
|
loadArrayDescExpr(arrNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3201
|
+
exprIsPtrSizedRead(rawNode: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3202
|
+
pushValueNeedsWiden(itemNode: CodeNode, value: string, lctx: LowIRLowerContext): boolean;
|
|
2287
3203
|
pushItemNeedsWiden(itemNode: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
2288
3204
|
arrayElemTypeName(arrNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3205
|
+
nodeIsArrayExpr(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3206
|
+
lowerArrayIndexOf(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3207
|
+
isArrayLiteralValue(nameNode: CodeNode, val: CodeNode): boolean;
|
|
3208
|
+
isArrayLiteralShape(val: CodeNode): boolean;
|
|
3209
|
+
arrayElemTypeOfTypeName(typeName: string): string;
|
|
3210
|
+
arrayLiteralElemType(nameNode: CodeNode, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3211
|
+
lowerArrayLiteral(nameNode: CodeNode, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3212
|
+
lowerArrayLiteralTyped(elemType: string, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2289
3213
|
lowerPush(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3214
|
+
lowerForMap(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
2290
3215
|
lowerFor(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
2291
3216
|
emitStrcmpEq(lhs: string, rhs: string, ctx: LowIRLowerContext): string;
|
|
3217
|
+
propertyReadClass(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3218
|
+
isPropertyReadNode(node: CodeNode): boolean;
|
|
3219
|
+
lowerPropertyRead(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3220
|
+
isLibmUnaryOp(op: string): boolean;
|
|
3221
|
+
isLibmBinaryOp(op: string): boolean;
|
|
3222
|
+
lowerLibmUnary(fnName: string, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3223
|
+
lowerLibmBinary(fnName: string, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2292
3224
|
lowerToString(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2293
3225
|
lowerStrFromCode(node: CodeNode, fnName: string, lctx: LowIRLowerContext): string;
|
|
3226
|
+
lowerStrlenOn(textNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3227
|
+
unwrapUnwrapOper(node: CodeNode): CodeNode;
|
|
2294
3228
|
lowerStrlen(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2295
3229
|
isIntArrayTypeNode(node: CodeNode): boolean;
|
|
3230
|
+
isIntKeyValueMapTypeNode(node: CodeNode): boolean;
|
|
3231
|
+
ensureIMapExterns(): void;
|
|
3232
|
+
widenToI64(val: string, keyNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3233
|
+
emitIMapCall(fnName: string, retType: string, desc: string, rest: Array<string>, restTypes: Array<string>, lctx: LowIRLowerContext): string;
|
|
3234
|
+
imapDescFromVref(vref: string, lctx: LowIRLowerContext): string;
|
|
3235
|
+
imapValueKind(vref: string, lctx: LowIRLowerContext): string;
|
|
3236
|
+
imapValueOwnKind(typeName: string): number;
|
|
2296
3237
|
isIntIntMapTypeNode(node: CodeNode): boolean;
|
|
3238
|
+
ensureSMapExterns(): void;
|
|
3239
|
+
emitSMapNew(lctx: LowIRLowerContext): string;
|
|
3240
|
+
emitSMapNewKind(valKind: number, lctx: LowIRLowerContext): string;
|
|
3241
|
+
smapValueOwnKind(valueTypeName: string): number;
|
|
3242
|
+
emitSMapCall(fnName: string, retType: string, descIn: string, rest: Array<string>, restTypes: Array<string>, lctx: LowIRLowerContext): string;
|
|
3243
|
+
lowerSMapKeys(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3244
|
+
lowerEnumRef(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3245
|
+
jsonTypeNameOfNode(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3246
|
+
nodeIsJson(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3247
|
+
jsonValueKind(valNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3248
|
+
ensureJsonExtern(fnName: string, retType: string, params: Array<string>): void;
|
|
3249
|
+
emitAnsiConst(code: string, lctx: LowIRLowerContext): string;
|
|
3250
|
+
tryLowerAnsi(opName: string, lctx: LowIRLowerContext): string;
|
|
3251
|
+
emitJsonCall(fnName: string, retType: string, args: Array<string>, argTypes: Array<string>, cParams: Array<string>, lctx: LowIRLowerContext): string;
|
|
3252
|
+
lowerJsonNew(fnName: string, lctx: LowIRLowerContext): string;
|
|
3253
|
+
lowerJsonGet(node: CodeNode, fnName: string, retIr: string, cRet: string, lctx: LowIRLowerContext): string;
|
|
3254
|
+
lowerJsonSet(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3255
|
+
lowerJsonPush(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3256
|
+
lowerJson1(node: CodeNode, fnName: string, cRet: string, lctx: LowIRLowerContext): string;
|
|
3257
|
+
lowerJsonGetValue(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3258
|
+
jsonCaseKindFor(typeName: string): number;
|
|
3259
|
+
lowerJsonCase(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3260
|
+
lowerArraySort(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3261
|
+
lowerArrayInsert(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3262
|
+
emitArrayRemoveCall(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3263
|
+
lowerArrayRemove(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3264
|
+
lowerArrayRemoveLast(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3265
|
+
lowerArrayClear(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3266
|
+
lowerArrayExtract(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3267
|
+
lowerTernary(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3268
|
+
lowerArrayReverse(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3269
|
+
toI1(v: string, lctx: LowIRLowerContext): string;
|
|
3270
|
+
lowerStr2Fn(node: CodeNode, fnName: string, retType: string, lctx: LowIRLowerContext): string;
|
|
3271
|
+
lowerStr3Fn(node: CodeNode, fnName: string, lctx: LowIRLowerContext): string;
|
|
3272
|
+
lowerStr2IntFn(node: CodeNode, fnName: string, retType: string, lctx: LowIRLowerContext): string;
|
|
3273
|
+
lowerStr1IntFn(node: CodeNode, fnName: string, retType: string, lctx: LowIRLowerContext): string;
|
|
3274
|
+
lowerStr0Fn(fnName: string, lctx: LowIRLowerContext): string;
|
|
3275
|
+
lowerStr1Fn(node: CodeNode, fnName: string, lctx: LowIRLowerContext): string;
|
|
3276
|
+
isStringKeyMapTypeNode(node: CodeNode): boolean;
|
|
2297
3277
|
isObjectPtrArrayTypeNode(node: CodeNode): boolean;
|
|
3278
|
+
isPlainValueArrayTypeNode(node: CodeNode): boolean;
|
|
3279
|
+
isDoubleArrayTypeNode(node: CodeNode): boolean;
|
|
3280
|
+
arrayElemIsDouble(arrNode: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
2298
3281
|
isStringArrayTypeNode(node: CodeNode): boolean;
|
|
2299
3282
|
emitPtrArrayNewEmpty(lctx: LowIRLowerContext, elemKind: number): string;
|
|
3283
|
+
isOwnedCollectionLocal(varName: string, lctx: LowIRLowerContext): boolean;
|
|
2300
3284
|
bindPtrArraySlot(varName: string, desc: string, lctx: LowIRLowerContext, owned: boolean): void;
|
|
2301
3285
|
wasmCollectionRcEnabled(lctx: LowIRLowerContext): boolean;
|
|
2302
3286
|
collectionKind(varName: string, lctx: LowIRLowerContext): string;
|
|
@@ -2321,14 +3305,30 @@ export declare class LowIRBuilderPass {
|
|
|
2321
3305
|
lowerCollectionLen(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2322
3306
|
lowerCollectionHas(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2323
3307
|
lowerCollectionSet(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3308
|
+
collectStructVars(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): Array<RangerAppParamDesc>;
|
|
3309
|
+
collectStructVarsInto(cl: RangerAppClassDesc, ctx: RangerAppWriterContext, out: Array<RangerAppParamDesc>, seen: {
|
|
3310
|
+
[key: string]: boolean;
|
|
3311
|
+
}, depth: number): void;
|
|
2324
3312
|
lowerStruct(cl: RangerAppClassDesc, ctx: RangerAppWriterContext): void;
|
|
2325
3313
|
lowerTypeDesc(st: LowIRStruct, target: LowIRTarget): void;
|
|
2326
3314
|
fieldByteOffset(className: string, fieldIndex: number, module: LowIRModule): number;
|
|
3315
|
+
shadowBind(varName: string, irType: string, value: string, lctx: LowIRLowerContext): string;
|
|
3316
|
+
restoreShadow(varName: string, prev: string, lctx: LowIRLowerContext): void;
|
|
3317
|
+
takeForceFresh(varName: string, lctx: LowIRLowerContext): boolean;
|
|
2327
3318
|
bindSlot(varName: string, irType: string, value: string, lctx: LowIRLowerContext): void;
|
|
2328
3319
|
loadSlot(varName: string, irType: string, lctx: LowIRLowerContext): string;
|
|
3320
|
+
loadSlotRaw(varName: string, irType: string, lctx: LowIRLowerContext): string;
|
|
3321
|
+
isParamName(varName: string, lctx: LowIRLowerContext): boolean;
|
|
2329
3322
|
fieldIrTypeFor(className: string, fieldName: string): string;
|
|
2330
3323
|
fieldIsPtrArraySlot(className: string, fieldName: string): boolean;
|
|
2331
3324
|
fieldIsObjectSlot(className: string, fieldName: string): boolean;
|
|
3325
|
+
strKeyPtr(keyNode: CodeNode, key: string, lctx: LowIRLowerContext): string;
|
|
3326
|
+
smapDescFromVref(vref: string, lctx: LowIRLowerContext): string;
|
|
3327
|
+
isStringMapVref(vref: string, lctx: LowIRLowerContext): boolean;
|
|
3328
|
+
smapValueKind(vref: string, lctx: LowIRLowerContext): string;
|
|
3329
|
+
smapValueIsInt(vref: string, lctx: LowIRLowerContext): boolean;
|
|
3330
|
+
fieldIsIntMapSlot(className: string, fieldName: string): boolean;
|
|
3331
|
+
fieldIsStringMapSlot(className: string, fieldName: string): boolean;
|
|
2332
3332
|
fieldIsStringSlot(className: string, fieldName: string): boolean;
|
|
2333
3333
|
fieldIsBufferSlot(className: string, fieldName: string): boolean;
|
|
2334
3334
|
fieldIsBoolSlot(className: string, fieldName: string): boolean;
|
|
@@ -2342,6 +3342,12 @@ export declare class LowIRBuilderPass {
|
|
|
2342
3342
|
emitPtrArrayElemSet(desc: string, idx: string, val: string, arrNode: CodeNode, lctx: LowIRLowerContext): void;
|
|
2343
3343
|
emitFieldLoadOn(className: string, structPtr: string, fieldName: string, lctx: LowIRLowerContext): string;
|
|
2344
3344
|
emitReleaseFieldValue(className: string, fieldName: string, rawVal: string, lctx: LowIRLowerContext): void;
|
|
3345
|
+
exprCarriesFreshRef(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3346
|
+
exprIsBorrowedPtrArrayRef(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3347
|
+
retainAliasedArray(valNode: CodeNode, desc: string, lctx: LowIRLowerContext): void;
|
|
3348
|
+
isBorrowedArrayExpr(valNode: CodeNode): boolean;
|
|
3349
|
+
emitSMapRetain(desc: string, lctx: LowIRLowerContext): void;
|
|
3350
|
+
emitPtrArrayRetain(desc: string, lctx: LowIRLowerContext): void;
|
|
2345
3351
|
emitFieldStoreOn(className: string, structPtr: string, fieldName: string, value: string, lctx: LowIRLowerContext): void;
|
|
2346
3352
|
emitFieldStoreOnEx(className: string, structPtr: string, fieldName: string, value: string, srcIsFresh: boolean, lctx: LowIRLowerContext): void;
|
|
2347
3353
|
emitObjRetainPtr(ptr: string, lctx: LowIRLowerContext): void;
|
|
@@ -2364,26 +3370,43 @@ export declare class LowIRBuilderPass {
|
|
|
2364
3370
|
initArrayFieldsInConstructor(className: string, lctx: LowIRLowerContext): void;
|
|
2365
3371
|
structByteSize(className: string, module: LowIRModule): number;
|
|
2366
3372
|
classHasOwnedFields(className: string): boolean;
|
|
2367
|
-
|
|
3373
|
+
newArgListOf(argsNode: CodeNode): CodeNode;
|
|
3374
|
+
lowerNewObject(className: string, argsNodeIn: CodeNode, lctx: LowIRLowerContext): string;
|
|
2368
3375
|
findFieldIndex(className: string, fieldName: string, module: LowIRModule): number;
|
|
3376
|
+
resolvesToField(fieldName: string, lctx: LowIRLowerContext): boolean;
|
|
3377
|
+
isRealConstructor(fnDesc: RangerAppFunctionDesc, className: string, appCtx: RangerAppWriterContext): boolean;
|
|
2369
3378
|
isClassField(fieldName: string, className: string, module: LowIRModule): boolean;
|
|
2370
3379
|
structFieldCount(className: string, module: LowIRModule): number;
|
|
2371
3380
|
lowerFunction(fnDesc: RangerAppFunctionDesc, className: string, appCtx: RangerAppWriterContext, exportFn: boolean, isMain: boolean, isInstance: boolean): void;
|
|
2372
3381
|
lowerSingletonAccessor(cl: RangerAppClassDesc, appCtx: RangerAppWriterContext): void;
|
|
2373
3382
|
collectLambdas(appCtx: RangerAppWriterContext): void;
|
|
2374
3383
|
collectMethodLambdas(m: RangerAppFunctionDesc, pt: string): void;
|
|
3384
|
+
collectMethodLambdasAt(m: RangerAppFunctionDesc, pt: string, depth: number): void;
|
|
2375
3385
|
lambdaCallSig(lam: RangerAppFunctionDesc, pt: string): string;
|
|
2376
3386
|
addLambdaSig(sig: string): void;
|
|
2377
3387
|
lowerLambdaBodies(appCtx: RangerAppWriterContext): void;
|
|
2378
3388
|
lowerLambdaFunction(lam: RangerAppFunctionDesc, fnName: string, appCtx: RangerAppWriterContext): void;
|
|
2379
3389
|
lambdaTableIndex(name: string): number;
|
|
2380
3390
|
nodeAssignsToName(node: CodeNode, name: string): boolean;
|
|
3391
|
+
boxedCellType(varName: string, lctx: LowIRLowerContext): string;
|
|
3392
|
+
emitBoxCell(lctx: LowIRLowerContext): string;
|
|
3393
|
+
boxInitValue(irType: string, value: string, lctx: LowIRLowerContext): string;
|
|
3394
|
+
bindBoxedLocal(varName: string, irType: string, value: string, lctx: LowIRLowerContext): void;
|
|
3395
|
+
isBoxableIrType(irType: string): boolean;
|
|
3396
|
+
boxedStorageType(logicalType: string): string;
|
|
3397
|
+
widenForBoxCell(value: string, logicalType: string, lctx: LowIRLowerContext): string;
|
|
3398
|
+
emitBoxCellSized(lctx: LowIRLowerContext, byteSize: number): string;
|
|
2381
3399
|
computeBoxedCandidates(fnDesc: RangerAppFunctionDesc, lctx: LowIRLowerContext): void;
|
|
2382
3400
|
collectBoxedCandidates(m: RangerAppFunctionDesc, lctx: LowIRLowerContext): void;
|
|
3401
|
+
irTypeBytes(irType: string, lctx: LowIRLowerContext): number;
|
|
3402
|
+
lambdaOwnerClass(lam: RangerAppFunctionDesc, depth: number): string;
|
|
3403
|
+
lambdaCaptureNames(node: CodeNode, lam: RangerAppFunctionDesc): Array<string>;
|
|
3404
|
+
nestedCaptureNames(lam: RangerAppFunctionDesc, depth: number): Array<string>;
|
|
2383
3405
|
computeLambdaCaptures(node: CodeNode, lam: RangerAppFunctionDesc, lctx: LowIRLowerContext): LambdaCaptureInfo;
|
|
2384
3406
|
lowerLambdaValue(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2385
3407
|
lowerLambdaCall(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2386
3408
|
isOwnedObjectLocal(varName: string, lctx: LowIRLowerContext): boolean;
|
|
3409
|
+
slotHoldsObject(varName: string, lctx: LowIRLowerContext): boolean;
|
|
2387
3410
|
releaseOwnedLocal(varName: string, lctx: LowIRLowerContext): void;
|
|
2388
3411
|
isOwnedStringLocal(varName: string, lctx: LowIRLowerContext): boolean;
|
|
2389
3412
|
registerFreshStringTemp(tmp: string, lctx: LowIRLowerContext): void;
|
|
@@ -2396,15 +3419,25 @@ export declare class LowIRBuilderPass {
|
|
|
2396
3419
|
releaseOwnedString(varName: string, lctx: LowIRLowerContext): void;
|
|
2397
3420
|
releaseOwnedCollectionLocal(varName: string, lctx: LowIRLowerContext): void;
|
|
2398
3421
|
emitOwnedStringInit(varName: string, valNode: CodeNode, strPtr: string, lctx: LowIRLowerContext): string;
|
|
3422
|
+
isCapturedName(varName: string, lctx: LowIRLowerContext): boolean;
|
|
2399
3423
|
emitOwnedStringReassign(varName: string, valNode: CodeNode, strPtr: string, lctx: LowIRLowerContext): string;
|
|
2400
3424
|
strictOwnershipEnabled(lctx: LowIRLowerContext): boolean;
|
|
2401
3425
|
emitOwnershipSummary(lctx: LowIRLowerContext): void;
|
|
2402
3426
|
emitReleaseOwnedLocals(lctx: LowIRLowerContext): void;
|
|
3427
|
+
withoutName(names: Array<string>, varName: string): Array<string>;
|
|
3428
|
+
popReslots(mark: number, lctx: LowIRLowerContext): void;
|
|
2403
3429
|
lowerBlock(block: CodeNode, lctx: LowIRLowerContext): void;
|
|
3430
|
+
blockClosed(lctx: LowIRLowerContext): boolean;
|
|
3431
|
+
lowerStmtList(stmts: Array<CodeNode>, lctx: LowIRLowerContext): void;
|
|
3432
|
+
lowerBlockBody(block: CodeNode, lctx: LowIRLowerContext): void;
|
|
2404
3433
|
isAssignNode(node: CodeNode): boolean;
|
|
2405
3434
|
lowerStmt(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
2406
3435
|
lowerStmtDispatch(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3436
|
+
declaredIrTypeOf(nameNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3437
|
+
noteRedeclaration(varName: string, nameNode: CodeNode, lctx: LowIRLowerContext): void;
|
|
2407
3438
|
lowerVarDef(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3439
|
+
lowerVarDefBody(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3440
|
+
exprIsI64Operator(node: CodeNode): boolean;
|
|
2408
3441
|
assignTargetFieldClass(varName: string, lctx: LowIRLowerContext): string;
|
|
2409
3442
|
lowerAssign(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
2410
3443
|
lowerReturn(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
@@ -2413,9 +3446,26 @@ export declare class LowIRBuilderPass {
|
|
|
2413
3446
|
unwrapCondExpr(node: CodeNode): CodeNode;
|
|
2414
3447
|
exprProducesI1(node: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
2415
3448
|
condVref(node: CodeNode): string;
|
|
3449
|
+
lowerCondOperand(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2416
3450
|
lowerCond(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3451
|
+
emitSwitchCaseTest(subj: string, subjNode: CodeNode, caseNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
3452
|
+
emitStrOrDefault(value: string, fallback: string, lctx: LowIRLowerContext): string;
|
|
3453
|
+
lowerThrow(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3454
|
+
emptyStrList(): Array<string>;
|
|
3455
|
+
lowerTry(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3456
|
+
guardUnwrapInTry(value: string, lctx: LowIRLowerContext): void;
|
|
3457
|
+
lowerSwitch(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3458
|
+
shapeCaseClassName(itemNode: CodeNode): string;
|
|
3459
|
+
moduleHasTypeDesc(className: string): boolean;
|
|
3460
|
+
emitShapeKindTest(val: string, caseClass: string, lctx: LowIRLowerContext): string;
|
|
3461
|
+
lowerShapeIs(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3462
|
+
lowerShapeCase(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
2417
3463
|
lowerIf(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3464
|
+
emitLoopBodyReleases(lctx: LowIRLowerContext): void;
|
|
3465
|
+
lowerLoopJump(target: string, lctx: LowIRLowerContext): void;
|
|
2418
3466
|
lowerWhile(node: CodeNode, lctx: LowIRLowerContext): void;
|
|
3467
|
+
releaseAndClearOwnedLocal(varName: string, lctx: LowIRLowerContext): void;
|
|
3468
|
+
releaseAndClearOwnedCollection(varName: string, lctx: LowIRLowerContext): void;
|
|
2419
3469
|
releaseLoopBodyOwned(ownedBefore: number, ownedStrBefore: number, ownedCollBefore: number, lctx: LowIRLowerContext): void;
|
|
2420
3470
|
lowerExpr(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2421
3471
|
operatorReturnsString(op: string): boolean;
|
|
@@ -2425,20 +3475,40 @@ export declare class LowIRBuilderPass {
|
|
|
2425
3475
|
lowerCompareI32(aNode: CodeNode, bNode: CodeNode, pred: string, lctx: LowIRLowerContext): string;
|
|
2426
3476
|
lowerArithF64OrI32(intKind: string, fpKind: string, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2427
3477
|
lowerBinaryOp(opName: string, node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3478
|
+
lowerShortCircuit(node: CodeNode, isAnd: boolean, lctx: LowIRLowerContext): string;
|
|
2428
3479
|
tryLowerIntrinsic(fnName: string, argsNode: CodeNode, lctx: LowIRLowerContext): string;
|
|
2429
3480
|
finishObjectCall(rv: string): string;
|
|
2430
3481
|
lowerCall(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3482
|
+
exprRecvClassName(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2431
3483
|
tryLowerObjectCall(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
2432
3484
|
fieldReceiverClass(recvName: string, lctx: LowIRLowerContext): string;
|
|
2433
3485
|
callArgsNode(node: CodeNode): CodeNode;
|
|
2434
3486
|
resolveMethodName(node: CodeNode, defaultName: string): string;
|
|
2435
3487
|
argIrType(arg: CodeNode, lctx: LowIRLowerContext): string;
|
|
3488
|
+
lowerCallArgValue(arg: CodeNode, paramIndex: number, fnDesc: RangerAppFunctionDesc, lctx: LowIRLowerContext): string;
|
|
2436
3489
|
paramIrTypeFromDesc(paramIndex: number, fnDesc: RangerAppFunctionDesc, lctx: LowIRLowerContext): string;
|
|
3490
|
+
coerceArg(value: string, wantType: string, lctx: LowIRLowerContext): string;
|
|
3491
|
+
methodOwnerClass(className: string, methodName: string, lctx: LowIRLowerContext): string;
|
|
3492
|
+
methodOwnerClassIn(className: string, methodName: string, appCtx: RangerAppWriterContext, depth: number): string;
|
|
3493
|
+
virtualKeyOf(className: string, methodName: string): string;
|
|
3494
|
+
topmostDeclaringClass(className: string, methodName: string, appCtx: RangerAppWriterContext, depth: number): string;
|
|
3495
|
+
classIsLowered(cl: RangerAppClassDesc): boolean;
|
|
3496
|
+
collectVirtualMethods(appCtx: RangerAppWriterContext): void;
|
|
3497
|
+
classInheritsFrom(className: string, baseName: string, appCtx: RangerAppWriterContext, depth: number): boolean;
|
|
3498
|
+
virtualDispatcherName(className: string, methodName: string): string;
|
|
3499
|
+
hasVirtualDispatcher(className: string, methodName: string): boolean;
|
|
3500
|
+
emitVirtualDispatchers(appCtx: RangerAppWriterContext): void;
|
|
3501
|
+
emitOneVirtualDispatcher(top: string, meth: string, fnDesc: RangerAppFunctionDesc, cases: Array<string>, appCtx: RangerAppWriterContext): void;
|
|
3502
|
+
emitDispatchTailCall(builder: LowIRBuilder, cls: string, meth: string, retType: string, argNames: Array<string>, argTypes: Array<string>): void;
|
|
2437
3503
|
lowerInstanceCallOn(node: CodeNode, receiverName: string, recvNode: CodeNode, methodName: string, lctx: LowIRLowerContext): string;
|
|
3504
|
+
registerCallObjectTemp(node: CodeNode, tmp: string, lctx: LowIRLowerContext): void;
|
|
2438
3505
|
lowerInstanceCall(node: CodeNode, lctx: LowIRLowerContext): string;
|
|
3506
|
+
calleeReceiverIsUnknown(callee: CodeNode, lctx: LowIRLowerContext): boolean;
|
|
3507
|
+
moduleHasFunction(fnName: string): boolean;
|
|
2439
3508
|
resolveCalleeName(callee: CodeNode): string;
|
|
2440
3509
|
}
|
|
2441
3510
|
export declare class LLVMIRWriter {
|
|
3511
|
+
instrLineLen: number;
|
|
2442
3512
|
varargNames: Array<string>;
|
|
2443
3513
|
varargSigs: Array<string>;
|
|
2444
3514
|
constructor();
|
|
@@ -2450,11 +3520,14 @@ export declare class LLVMIRWriter {
|
|
|
2450
3520
|
hexByte(b: number): string;
|
|
2451
3521
|
llvmEscapeCString(text: string): string;
|
|
2452
3522
|
writeModule(module: LowIRModule, wr: CodeWriter): void;
|
|
3523
|
+
writeBigStackMain(wr: CodeWriter): void;
|
|
3524
|
+
writeLambdaTable(module: LowIRModule, wr: CodeWriter): void;
|
|
2453
3525
|
writeTypeDescs(module: LowIRModule, wr: CodeWriter): void;
|
|
2454
3526
|
writeOneTypeDesc(td: LowIRTypeDesc, wr: CodeWriter): void;
|
|
2455
3527
|
writeStruct(st: LowIRStruct, wr: CodeWriter): void;
|
|
2456
3528
|
writeFunction(fn: LowIRFunction, wr: CodeWriter): void;
|
|
2457
3529
|
writeInstr(ins: LowIRInstr, wr: CodeWriter): void;
|
|
3530
|
+
writeInstrBody(ins: LowIRInstr, wr: CodeWriter): void;
|
|
2458
3531
|
writeTerminator(bb: LowIRBlock, wr: CodeWriter): void;
|
|
2459
3532
|
}
|
|
2460
3533
|
export declare class WATWriter {
|
|
@@ -2570,7 +3643,9 @@ export declare class LiveCompiler {
|
|
|
2570
3643
|
localCall(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<boolean>;
|
|
2571
3644
|
finishWalkNode(wr: CodeWriter): void;
|
|
2572
3645
|
WalkNode(node: CodeNode, in_ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
3646
|
+
typeNameToIdentifier(ss: string): string;
|
|
2573
3647
|
walkCommandList(cmd: CodeNode, node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
3648
|
+
isMutatingOpName(n: string): boolean;
|
|
2574
3649
|
walkCommand(cmd: CodeNode, node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
2575
3650
|
compile(node: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): void;
|
|
2576
3651
|
findParamDesc(obj: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): RangerAppParamDesc | undefined;
|
|
@@ -2631,6 +3706,396 @@ export declare class CLIProgress {
|
|
|
2631
3706
|
printFlag(flag: string, description: string): void;
|
|
2632
3707
|
printSection(title: string): void;
|
|
2633
3708
|
}
|
|
3709
|
+
export declare class GitSha1 {
|
|
3710
|
+
constructor();
|
|
3711
|
+
static mask32(): number;
|
|
3712
|
+
static add32(a: number, b: number): number;
|
|
3713
|
+
static not32(x: number): number;
|
|
3714
|
+
static rotl(x: number, n: number): number;
|
|
3715
|
+
static copyRange(data: Uint8Array, start: number, count: number): Uint8Array;
|
|
3716
|
+
static ascii(data: Uint8Array, start: number, count: number): string;
|
|
3717
|
+
static u32be(data: Uint8Array, i: number): number;
|
|
3718
|
+
static hexDigit(d: number): string;
|
|
3719
|
+
static toHex(data: Uint8Array): string;
|
|
3720
|
+
static fromHex(hex: string): Uint8Array;
|
|
3721
|
+
static hash(data: Uint8Array): Uint8Array;
|
|
3722
|
+
static writeU32be(out: Uint8Array, i: number, v: number): void;
|
|
3723
|
+
static hashHex(data: Uint8Array): string;
|
|
3724
|
+
static objectId(kind: string, payload: Uint8Array): string;
|
|
3725
|
+
static hexEq(a: string, b: string): boolean;
|
|
3726
|
+
}
|
|
3727
|
+
export declare class GitPkt {
|
|
3728
|
+
ok: boolean;
|
|
3729
|
+
err: string;
|
|
3730
|
+
lines: Array<string>;
|
|
3731
|
+
raw: Array<Uint8Array>;
|
|
3732
|
+
isFlush: Array<boolean>;
|
|
3733
|
+
constructor();
|
|
3734
|
+
}
|
|
3735
|
+
export declare class GitRef {
|
|
3736
|
+
name: string;
|
|
3737
|
+
sha: string;
|
|
3738
|
+
peeled: string;
|
|
3739
|
+
constructor();
|
|
3740
|
+
}
|
|
3741
|
+
export declare class GitAdvertisement {
|
|
3742
|
+
ok: boolean;
|
|
3743
|
+
err: string;
|
|
3744
|
+
service: string;
|
|
3745
|
+
caps: string;
|
|
3746
|
+
head: string;
|
|
3747
|
+
refs: Array<GitRef>;
|
|
3748
|
+
constructor();
|
|
3749
|
+
}
|
|
3750
|
+
export declare class GitWant {
|
|
3751
|
+
ok: boolean;
|
|
3752
|
+
err: string;
|
|
3753
|
+
sha: string;
|
|
3754
|
+
body: Uint8Array;
|
|
3755
|
+
constructor();
|
|
3756
|
+
}
|
|
3757
|
+
export declare class GitSideband {
|
|
3758
|
+
ok: boolean;
|
|
3759
|
+
err: string;
|
|
3760
|
+
pack: Uint8Array;
|
|
3761
|
+
progress: string;
|
|
3762
|
+
constructor();
|
|
3763
|
+
}
|
|
3764
|
+
export declare class GitPktIO {
|
|
3765
|
+
constructor();
|
|
3766
|
+
static hexVal(ch: string): number;
|
|
3767
|
+
static parseHex4(data: Uint8Array, at: number): number;
|
|
3768
|
+
static hex4(n: number): string;
|
|
3769
|
+
static encodeLine(text: string): Uint8Array;
|
|
3770
|
+
static encodeFlush(): Uint8Array;
|
|
3771
|
+
static parse(data: Uint8Array): GitPkt;
|
|
3772
|
+
static parseAdvertisement(data: Uint8Array): GitAdvertisement;
|
|
3773
|
+
static findRef(adv: GitAdvertisement, spec: string): string;
|
|
3774
|
+
static hasToken(caps: string, name: string): boolean;
|
|
3775
|
+
static joinBuf(parts: Array<Uint8Array>): Uint8Array;
|
|
3776
|
+
static encodeDelim(): Uint8Array;
|
|
3777
|
+
static buildWant(adv: GitAdvertisement, spec: string): GitWant;
|
|
3778
|
+
static buildWantFetch(sha: string, deepen: number, filter: string, extras: Array<string>): GitWant;
|
|
3779
|
+
static buildWantTrees(adv: GitAdvertisement, spec: string): GitWant;
|
|
3780
|
+
static buildWantSha(sha: string): GitWant;
|
|
3781
|
+
static buildFetchV2(sha: string, deepen: number, filter: string): GitWant;
|
|
3782
|
+
static demux(data: Uint8Array): GitSideband;
|
|
3783
|
+
static indexOfPack(data: Uint8Array): number;
|
|
3784
|
+
static indexOfChar(s: string, code: number): number;
|
|
3785
|
+
static trimNl(s: string): string;
|
|
3786
|
+
}
|
|
3787
|
+
export declare class ZipBuffer {
|
|
3788
|
+
data: Uint8Array;
|
|
3789
|
+
pos: number;
|
|
3790
|
+
length: number;
|
|
3791
|
+
constructor();
|
|
3792
|
+
initWithBuffer(buf: Uint8Array): void;
|
|
3793
|
+
initWithSize(size: number): void;
|
|
3794
|
+
getPosition(): number;
|
|
3795
|
+
setPosition(newPos: number): void;
|
|
3796
|
+
seek(offset: number): void;
|
|
3797
|
+
skip(count: number): void;
|
|
3798
|
+
remaining(): number;
|
|
3799
|
+
isEOF(): boolean;
|
|
3800
|
+
readUint8(): number;
|
|
3801
|
+
readUint16LE(): number;
|
|
3802
|
+
readUint32LE(): number;
|
|
3803
|
+
readBytes(count: number): Uint8Array;
|
|
3804
|
+
readString(count: number): string;
|
|
3805
|
+
peekUint8(): number;
|
|
3806
|
+
peekUint32LE(): number;
|
|
3807
|
+
writeUint8(value: number): void;
|
|
3808
|
+
writeUint16LE(value: number): void;
|
|
3809
|
+
writeUint32LE(value: number): void;
|
|
3810
|
+
writeBytes(src: Uint8Array, srcOffset: number, count: number): void;
|
|
3811
|
+
writeBuffer(src: Uint8Array): void;
|
|
3812
|
+
writeString(s: string): void;
|
|
3813
|
+
getBuffer(): Uint8Array;
|
|
3814
|
+
getLength(): number;
|
|
3815
|
+
findSignatureBackward(sig: number, startPos: number): number;
|
|
3816
|
+
}
|
|
3817
|
+
export declare class GrowableZipBuffer {
|
|
3818
|
+
chunks: Array<Uint8Array>;
|
|
3819
|
+
chunkLens: Array<number>;
|
|
3820
|
+
chunkSize: number;
|
|
3821
|
+
currentChunk: Uint8Array;
|
|
3822
|
+
currentPos: number;
|
|
3823
|
+
totalSize: number;
|
|
3824
|
+
constructor();
|
|
3825
|
+
setChunkSize(size: number): void;
|
|
3826
|
+
allocateNewChunk(): void;
|
|
3827
|
+
writeUint8(value: number): void;
|
|
3828
|
+
writeUint16LE(value: number): void;
|
|
3829
|
+
writeUint32LE(value: number): void;
|
|
3830
|
+
writeBytes(src: Uint8Array, srcOffset: number, count: number): void;
|
|
3831
|
+
writeBuffer(src: Uint8Array): void;
|
|
3832
|
+
writeString(s: string): void;
|
|
3833
|
+
getSize(): number;
|
|
3834
|
+
toBuffer(): Uint8Array;
|
|
3835
|
+
}
|
|
3836
|
+
export declare class InflateHuffmanTable {
|
|
3837
|
+
counts: Array<number>;
|
|
3838
|
+
symbols: Array<number>;
|
|
3839
|
+
maxBits: number;
|
|
3840
|
+
constructor();
|
|
3841
|
+
build(lengths: Array<number>, numSymbols: number): void;
|
|
3842
|
+
decode(reader: InflateBitReader): number;
|
|
3843
|
+
}
|
|
3844
|
+
export declare class InflateBitReader {
|
|
3845
|
+
data: Uint8Array;
|
|
3846
|
+
bytePos: number;
|
|
3847
|
+
bitPos: number;
|
|
3848
|
+
currentByte: number;
|
|
3849
|
+
dataLength: number;
|
|
3850
|
+
constructor();
|
|
3851
|
+
init(buf: Uint8Array, offset: number, length: number): void;
|
|
3852
|
+
readBit(): number;
|
|
3853
|
+
readBits(count: number): number;
|
|
3854
|
+
alignToByte(): void;
|
|
3855
|
+
readByte(): number;
|
|
3856
|
+
readUint16LE(): number;
|
|
3857
|
+
getBytePosition(): number;
|
|
3858
|
+
isEOF(): boolean;
|
|
3859
|
+
}
|
|
3860
|
+
export declare class Inflate {
|
|
3861
|
+
input: Uint8Array;
|
|
3862
|
+
reader: InflateBitReader;
|
|
3863
|
+
outBuf: Uint8Array;
|
|
3864
|
+
outLen: number;
|
|
3865
|
+
outCap: number;
|
|
3866
|
+
fixedLitLen: InflateHuffmanTable;
|
|
3867
|
+
fixedDist: InflateHuffmanTable;
|
|
3868
|
+
fixedTablesBuilt: boolean;
|
|
3869
|
+
lengthBase: Array<number>;
|
|
3870
|
+
lengthExtra: Array<number>;
|
|
3871
|
+
distBase: Array<number>;
|
|
3872
|
+
distExtra: Array<number>;
|
|
3873
|
+
constructor();
|
|
3874
|
+
resetOutput(hint: number): void;
|
|
3875
|
+
ensureCapacity(extra: number): void;
|
|
3876
|
+
pushByte(b: number): void;
|
|
3877
|
+
finalOutput(): Uint8Array;
|
|
3878
|
+
buildLengthDistTables(): void;
|
|
3879
|
+
buildFixedTables(): void;
|
|
3880
|
+
decompress(data: Uint8Array): Uint8Array;
|
|
3881
|
+
decompressFrom(data: Uint8Array, offset: number): Uint8Array;
|
|
3882
|
+
inputPos(): number;
|
|
3883
|
+
decompressStored(): void;
|
|
3884
|
+
decompressHuffman(litLenTable: InflateHuffmanTable, distTable: InflateHuffmanTable): void;
|
|
3885
|
+
decompressDynamic(): void;
|
|
3886
|
+
copyFromOutput(distance: number, length: number): void;
|
|
3887
|
+
}
|
|
3888
|
+
export declare class GitZlib {
|
|
3889
|
+
ok: boolean;
|
|
3890
|
+
err: string;
|
|
3891
|
+
nextPos: number;
|
|
3892
|
+
constructor();
|
|
3893
|
+
inflateAt(data: Uint8Array, offset: number): Uint8Array;
|
|
3894
|
+
inflate(data: Uint8Array): Uint8Array;
|
|
3895
|
+
}
|
|
3896
|
+
export declare class GitObj {
|
|
3897
|
+
kind: number;
|
|
3898
|
+
sha: string;
|
|
3899
|
+
data: Uint8Array;
|
|
3900
|
+
packOff: number;
|
|
3901
|
+
resolved: boolean;
|
|
3902
|
+
delta: boolean;
|
|
3903
|
+
baseOff: number;
|
|
3904
|
+
baseSha: string;
|
|
3905
|
+
constructor();
|
|
3906
|
+
}
|
|
3907
|
+
export declare class GitPack {
|
|
3908
|
+
ok: boolean;
|
|
3909
|
+
err: string;
|
|
3910
|
+
version: number;
|
|
3911
|
+
count: number;
|
|
3912
|
+
objects: Array<GitObj>;
|
|
3913
|
+
bySha: {
|
|
3914
|
+
[key: string]: GitObj;
|
|
3915
|
+
};
|
|
3916
|
+
byOff: {
|
|
3917
|
+
[key: number]: GitObj;
|
|
3918
|
+
};
|
|
3919
|
+
constructor();
|
|
3920
|
+
}
|
|
3921
|
+
export declare class GitDelta {
|
|
3922
|
+
constructor();
|
|
3923
|
+
static varInt(data: Uint8Array, pos: Array<number>): number;
|
|
3924
|
+
static apply(src: Uint8Array, delta: Uint8Array): Uint8Array;
|
|
3925
|
+
}
|
|
3926
|
+
export declare class GitPackIO {
|
|
3927
|
+
constructor();
|
|
3928
|
+
static kindName(kind: number): string;
|
|
3929
|
+
static parse(data: Uint8Array): GitPack;
|
|
3930
|
+
static resolveDeltas(pack: GitPack): void;
|
|
3931
|
+
static lookup(pack: GitPack, sha: string): GitObj | undefined;
|
|
3932
|
+
static merge(a: GitPack, b: GitPack): GitPack;
|
|
3933
|
+
}
|
|
3934
|
+
export declare class GitEntry {
|
|
3935
|
+
name: string;
|
|
3936
|
+
sha: string;
|
|
3937
|
+
isTree: boolean;
|
|
3938
|
+
mode: string;
|
|
3939
|
+
constructor();
|
|
3940
|
+
}
|
|
3941
|
+
export declare class GitFile {
|
|
3942
|
+
path: string;
|
|
3943
|
+
data: Uint8Array;
|
|
3944
|
+
constructor();
|
|
3945
|
+
}
|
|
3946
|
+
export declare class GitTree {
|
|
3947
|
+
sha: string;
|
|
3948
|
+
entries: Array<GitEntry>;
|
|
3949
|
+
constructor();
|
|
3950
|
+
}
|
|
3951
|
+
export declare class GitMem {
|
|
3952
|
+
files: Array<GitFile>;
|
|
3953
|
+
paths: Array<string>;
|
|
3954
|
+
byPath: {
|
|
3955
|
+
[key: string]: GitFile;
|
|
3956
|
+
};
|
|
3957
|
+
constructor();
|
|
3958
|
+
}
|
|
3959
|
+
export declare class GitStore {
|
|
3960
|
+
pack: GitPack;
|
|
3961
|
+
ok: boolean;
|
|
3962
|
+
err: string;
|
|
3963
|
+
constructor(p: GitPack);
|
|
3964
|
+
takeObj(sha: string): GitObj | undefined;
|
|
3965
|
+
parseTree(payload: Uint8Array): GitTree;
|
|
3966
|
+
commitTree(payload: Uint8Array): string;
|
|
3967
|
+
checkout(sha: string, subdir: string): GitMem;
|
|
3968
|
+
walk(mem: GitMem, treeSha: string, prefix: string, want: string): void;
|
|
3969
|
+
mayEnter(path: string, want: string): boolean;
|
|
3970
|
+
splitSegs(path: string): Array<string>;
|
|
3971
|
+
asTreeSha(sha: string): string;
|
|
3972
|
+
treeAt(sha: string, subdir: string): string;
|
|
3973
|
+
underSubdir(path: string, want: string): boolean;
|
|
3974
|
+
stripSubdir(path: string, want: string): string;
|
|
3975
|
+
baseName(path: string): string;
|
|
3976
|
+
writeDisk(mem: GitMem, root: string): void;
|
|
3977
|
+
dirOf(path: string): string;
|
|
3978
|
+
splitPath(path: string): Array<string>;
|
|
3979
|
+
fileText(mem: GitMem, path: string): string;
|
|
3980
|
+
}
|
|
3981
|
+
export declare class PkgVal {
|
|
3982
|
+
kind: string;
|
|
3983
|
+
str: string;
|
|
3984
|
+
num: number;
|
|
3985
|
+
flag: boolean;
|
|
3986
|
+
keys: Array<string>;
|
|
3987
|
+
vals: Array<PkgVal>;
|
|
3988
|
+
constructor();
|
|
3989
|
+
}
|
|
3990
|
+
export declare class PkgJson {
|
|
3991
|
+
text: string;
|
|
3992
|
+
i: number;
|
|
3993
|
+
n: number;
|
|
3994
|
+
ok: boolean;
|
|
3995
|
+
err: string;
|
|
3996
|
+
constructor();
|
|
3997
|
+
parse(src: string): PkgVal;
|
|
3998
|
+
skip(): void;
|
|
3999
|
+
value(): PkgVal;
|
|
4000
|
+
object(): PkgVal;
|
|
4001
|
+
str(): string;
|
|
4002
|
+
num(): number;
|
|
4003
|
+
static child(obj: PkgVal, key: string): PkgVal | undefined;
|
|
4004
|
+
static strOf(obj: PkgVal, key: string): string;
|
|
4005
|
+
static intOf(obj: PkgVal, key: string): number;
|
|
4006
|
+
}
|
|
4007
|
+
export declare class PkgDep {
|
|
4008
|
+
name: string;
|
|
4009
|
+
path: string;
|
|
4010
|
+
git: string;
|
|
4011
|
+
rev: string;
|
|
4012
|
+
tag: string;
|
|
4013
|
+
subdir: string;
|
|
4014
|
+
constructor();
|
|
4015
|
+
}
|
|
4016
|
+
export declare class PkgManifest {
|
|
4017
|
+
name: string;
|
|
4018
|
+
version: string;
|
|
4019
|
+
entry: string;
|
|
4020
|
+
license: string;
|
|
4021
|
+
deps: Array<PkgDep>;
|
|
4022
|
+
ok: boolean;
|
|
4023
|
+
err: string;
|
|
4024
|
+
constructor();
|
|
4025
|
+
}
|
|
4026
|
+
export declare class PkgLockEnt {
|
|
4027
|
+
name: string;
|
|
4028
|
+
path: string;
|
|
4029
|
+
git: string;
|
|
4030
|
+
rev: string;
|
|
4031
|
+
subdir: string;
|
|
4032
|
+
sha256: string;
|
|
4033
|
+
constructor();
|
|
4034
|
+
}
|
|
4035
|
+
export declare class PkgLock {
|
|
4036
|
+
lockVersion: number;
|
|
4037
|
+
packages: Array<PkgLockEnt>;
|
|
4038
|
+
ok: boolean;
|
|
4039
|
+
err: string;
|
|
4040
|
+
constructor();
|
|
4041
|
+
}
|
|
4042
|
+
export declare class PkgManifestIO {
|
|
4043
|
+
constructor();
|
|
4044
|
+
static load(src: string): PkgManifest;
|
|
4045
|
+
static loadLock(src: string): PkgLock;
|
|
4046
|
+
static escape(s: string): string;
|
|
4047
|
+
static dumpLock(lock: PkgLock): string;
|
|
4048
|
+
static dumpManifest(m: PkgManifest): string;
|
|
4049
|
+
}
|
|
4050
|
+
export declare class PkgCache {
|
|
4051
|
+
constructor();
|
|
4052
|
+
static lessStr(a: string, b: string): boolean;
|
|
4053
|
+
static hashMem(mem: GitMem): string;
|
|
4054
|
+
static put(mem: GitMem, cacheRoot: string): string;
|
|
4055
|
+
static lockFor(name: string, git: string, rev: string, subdir: string, hash: string): PkgLockEnt;
|
|
4056
|
+
}
|
|
4057
|
+
export declare class PkgFetchWork {
|
|
4058
|
+
dir: string;
|
|
4059
|
+
man: PkgManifest;
|
|
4060
|
+
git: string;
|
|
4061
|
+
rev: string;
|
|
4062
|
+
subdir: string;
|
|
4063
|
+
fromGit: boolean;
|
|
4064
|
+
constructor();
|
|
4065
|
+
}
|
|
4066
|
+
export declare class PkgFetch {
|
|
4067
|
+
ok: boolean;
|
|
4068
|
+
err: string;
|
|
4069
|
+
cacheRoot: string;
|
|
4070
|
+
cacheOverride: string;
|
|
4071
|
+
rootDir: string;
|
|
4072
|
+
tmpRoot: string;
|
|
4073
|
+
httpTool: string;
|
|
4074
|
+
vendor: boolean;
|
|
4075
|
+
frozen: boolean;
|
|
4076
|
+
force: boolean;
|
|
4077
|
+
lock: PkgLock;
|
|
4078
|
+
previous: PkgLock;
|
|
4079
|
+
seen: {
|
|
4080
|
+
[key: string]: boolean;
|
|
4081
|
+
};
|
|
4082
|
+
lastRev: string;
|
|
4083
|
+
lastMem: GitMem;
|
|
4084
|
+
constructor();
|
|
4085
|
+
runHttp(args: Array<string>): boolean;
|
|
4086
|
+
advertise(url: string, dest: string): boolean;
|
|
4087
|
+
post(url: string, body: string, dest: string): boolean;
|
|
4088
|
+
fetchInto(name: string, url: string, wantRev: string, subdir: string): string;
|
|
4089
|
+
storeMem(mem: GitMem): string;
|
|
4090
|
+
cachedFor(env: InputEnv, name: string, git: string, rev: string, subdir: string): string;
|
|
4091
|
+
install(env: InputEnv, manDir: string): Promise<boolean>;
|
|
4092
|
+
oneDep(env: InputEnv, pending: Array<PkgFetchWork>, w: PkgFetchWork, d: PkgDep): Promise<boolean>;
|
|
4093
|
+
static findHttpTool(env: InputEnv): string;
|
|
4094
|
+
static splitPath(path: string): Array<string>;
|
|
4095
|
+
static readBytes(path: string): Uint8Array;
|
|
4096
|
+
static writeBytes(path: string, data: Uint8Array): void;
|
|
4097
|
+
static loadPack(path: string): GitPack;
|
|
4098
|
+
}
|
|
2634
4099
|
export declare class RangerDocGenerator {
|
|
2635
4100
|
constructor();
|
|
2636
4101
|
writeTypeDef(item: CodeNode, ctx: RangerAppWriterContext, wr: CodeWriter): Promise<void>;
|
|
@@ -2648,6 +4113,12 @@ export declare class StaticAnalyzer {
|
|
|
2648
4113
|
mutatingOps: {
|
|
2649
4114
|
[key: string]: boolean;
|
|
2650
4115
|
};
|
|
4116
|
+
own_call_params: Array<RangerAppParamDesc>;
|
|
4117
|
+
own_call_callees: Array<RangerAppFunctionDesc>;
|
|
4118
|
+
own_call_indexes: Array<number>;
|
|
4119
|
+
rss_edge_src: Array<RangerAppParamDesc>;
|
|
4120
|
+
rss_edge_dst: Array<RangerAppParamDesc>;
|
|
4121
|
+
rss_in_place: Array<RangerAppParamDesc>;
|
|
2651
4122
|
constructor();
|
|
2652
4123
|
initMutatingOps(): void;
|
|
2653
4124
|
isMutatingOperator(opName: string): boolean;
|
|
@@ -2655,6 +4126,8 @@ export declare class StaticAnalyzer {
|
|
|
2655
4126
|
getRootVarName(node: CodeNode): string;
|
|
2656
4127
|
isMemberAccess(node: CodeNode): boolean;
|
|
2657
4128
|
getMemberPath(node: CodeNode): string;
|
|
4129
|
+
isValuePassedType(t: number): boolean;
|
|
4130
|
+
isValuePassedCollection(typeNode: CodeNode): boolean;
|
|
2658
4131
|
markVarAsMutated(varName: string, fnCtx: RangerAppWriterContext): void;
|
|
2659
4132
|
analyzeVarDef(node: CodeNode): void;
|
|
2660
4133
|
walkForFieldAssignments(node: CodeNode, fnCtx: RangerAppWriterContext): void;
|
|
@@ -2678,6 +4151,7 @@ export declare class StaticAnalyzer {
|
|
|
2678
4151
|
analyzeTransitiveMutBorrow(fn: RangerAppFunctionDesc, changedParams: Array<string>): void;
|
|
2679
4152
|
analyzeClassTransitiveMutBorrow(cl: RangerAppClassDesc, changedParams: Array<string>): void;
|
|
2680
4153
|
checkDirectSelfMutation(fn: RangerAppFunctionDesc): boolean;
|
|
4154
|
+
writeTargetIsSelf(target: CodeNode): boolean;
|
|
2681
4155
|
nodeDirectlyMutatesSelf(node: CodeNode): boolean;
|
|
2682
4156
|
analyzeMethodMutation(fn: RangerAppFunctionDesc): boolean;
|
|
2683
4157
|
checkTransitiveMutation(node: CodeNode, fn: RangerAppFunctionDesc): boolean;
|
|
@@ -2692,11 +4166,58 @@ export declare class StaticAnalyzer {
|
|
|
2692
4166
|
isPrimitiveTypeName(name: string): boolean;
|
|
2693
4167
|
isHeapOwnedParam(p: RangerAppParamDesc): boolean;
|
|
2694
4168
|
recordEscape(valueName: string, ownerPath: string, via: string, fnCtx: RangerAppWriterContext): void;
|
|
2695
|
-
|
|
4169
|
+
escapeValueName(node: CodeNode): string;
|
|
4170
|
+
aliasRootOf(name: string, aliasNames: Array<string>, aliasRoots: Array<string>): string;
|
|
4171
|
+
recordEscapeAliased(valueName: string, ownerPath: string, via: string, fnCtx: RangerAppWriterContext, aliasNames: Array<string>, aliasRoots: Array<string>): void;
|
|
4172
|
+
callArgParam(arg: CodeNode, fnCtx: RangerAppWriterContext, aliasNames: Array<string>, aliasRoots: Array<string>): RangerAppParamDesc;
|
|
4173
|
+
markCallArgsResolved(argsNode: CodeNode, callee: RangerAppFunctionDesc, fnCtx: RangerAppWriterContext, aliasNames: Array<string>, aliasRoots: Array<string>): void;
|
|
4174
|
+
markCallArgsUnresolved(argsNode: CodeNode, fnCtx: RangerAppWriterContext, aliasNames: Array<string>, aliasRoots: Array<string>): void;
|
|
4175
|
+
collectCallArgEscapes(node: CodeNode, fnCtx: RangerAppWriterContext, aliasNames: Array<string>, aliasRoots: Array<string>): void;
|
|
4176
|
+
walkForEscapes(node: CodeNode, fnCtx: RangerAppWriterContext, aliasNames: Array<string>, aliasRoots: Array<string>): void;
|
|
2696
4177
|
ownerSuffix(param: RangerAppParamDesc): string;
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
4178
|
+
fnIsPure(fn: RangerAppFunctionDesc): boolean;
|
|
4179
|
+
classifyOwnership(fn: RangerAppFunctionDesc): void;
|
|
4180
|
+
resolveCallEscapes(): void;
|
|
4181
|
+
reportOwnership(fn: RangerAppFunctionDesc): void;
|
|
4182
|
+
reportOwnershipClass(cl: RangerAppClassDesc): void;
|
|
4183
|
+
analyzeOwnership(fn: RangerAppFunctionDesc): void;
|
|
4184
|
+
analyzeOwnershipClass(cl: RangerAppClassDesc): void;
|
|
4185
|
+
unionMemberIsScalarOnly(typeName: string): boolean;
|
|
4186
|
+
markClassShared(typeName: string, reason: string): void;
|
|
4187
|
+
classNameOfDesc(p: RangerAppParamDesc): string;
|
|
4188
|
+
sharedClassNameOf(name: string, fnCtx: RangerAppWriterContext): string;
|
|
4189
|
+
nodeClassNameOf(node: CodeNode, fnCtx: RangerAppWriterContext): string;
|
|
4190
|
+
collectMutatedNames(node: CodeNode, names: Array<string>): void;
|
|
4191
|
+
computeSharingMutations(): void;
|
|
4192
|
+
markSharingMutations(fn: RangerAppFunctionDesc): boolean;
|
|
4193
|
+
nameIn(name: string, names: Array<string>): boolean;
|
|
4194
|
+
varIsMutated(name: string, fnCtx: RangerAppWriterContext, mutated: Array<string>): boolean;
|
|
4195
|
+
readsStoredObject(node: CodeNode): boolean;
|
|
4196
|
+
walkForSharing(node: CodeNode, fnCtx: RangerAppWriterContext, fnName: string, mutated: Array<string>): void;
|
|
4197
|
+
markIdenticalOperandsShared(node: CodeNode, fnName: string): void;
|
|
4198
|
+
analyzeClassSharingFn(fn: RangerAppFunctionDesc): void;
|
|
4199
|
+
analyzeClassSharing(): void;
|
|
4200
|
+
reportClassSharing(): void;
|
|
4201
|
+
sharedClassOfDesc(p: RangerAppParamDesc): string;
|
|
4202
|
+
markDescRcWrap(p: RangerAppParamDesc): void;
|
|
4203
|
+
walkForSharedLocals(node: CodeNode): void;
|
|
4204
|
+
fnUsesThisValue(fn: RangerAppFunctionDesc): Promise<boolean>;
|
|
4205
|
+
fnSelfCallsNeedy(fn: RangerAppFunctionDesc): Promise<boolean>;
|
|
4206
|
+
computeSelfRcNeeds(): Promise<void>;
|
|
4207
|
+
markLambdaParamsRec(fn: RangerAppFunctionDesc): void;
|
|
4208
|
+
applySharedClassRcWrap(): void;
|
|
4209
|
+
rustParamHasRefSemantics(param: RangerAppParamDesc): boolean;
|
|
4210
|
+
rustBorrowedObjectParam(cl: RangerAppClassDesc, param: RangerAppParamDesc): boolean;
|
|
4211
|
+
rssPlainStringDesc(p: RangerAppParamDesc): boolean;
|
|
4212
|
+
rssResolveDesc(node: CodeNode): RangerAppParamDesc;
|
|
4213
|
+
rssSourceKind(value: CodeNode): number;
|
|
4214
|
+
rssRecordAssign(target: RangerAppParamDesc, value: CodeNode): void;
|
|
4215
|
+
rssLocalCandidate(p: RangerAppParamDesc): boolean;
|
|
4216
|
+
rssWalkBody(node: CodeNode): void;
|
|
4217
|
+
rssWalkFn(fn: RangerAppFunctionDesc): void;
|
|
4218
|
+
analyzeRustStaticStrings(): void;
|
|
4219
|
+
applyOwnershipToRustBorrowsFn(cl: RangerAppClassDesc, fn: RangerAppFunctionDesc): void;
|
|
4220
|
+
applyOwnershipToRustBorrows(): void;
|
|
2700
4221
|
analyzeOwnershipAll(strict: boolean): void;
|
|
2701
4222
|
analyzeAll(): void;
|
|
2702
4223
|
}
|
|
@@ -2734,6 +4255,7 @@ export declare class VirtualCompiler {
|
|
|
2734
4255
|
fillStr(cnt: number): string;
|
|
2735
4256
|
detectLanguageFromExtension(filename: string): string;
|
|
2736
4257
|
isTypeScriptExtension(filename: string): boolean;
|
|
4258
|
+
runInstall(env: InputEnv, params: CmdParams, cli: CLIProgress): Promise<boolean>;
|
|
2737
4259
|
run(env: InputEnv): Promise<CompilerResults>;
|
|
2738
4260
|
static create_env(): Promise<void>;
|
|
2739
4261
|
static displayCompilerErrorsWithCLI(appCtx: RangerAppWriterContext, cli: CLIProgress): void;
|
|
@@ -2744,4 +4266,3 @@ export declare class CompilerInterface {
|
|
|
2744
4266
|
constructor();
|
|
2745
4267
|
static create_env(): InputEnv;
|
|
2746
4268
|
}
|
|
2747
|
-
export {};
|