@ai-ecoverse/slicc-kernel 1.142.3 → 1.143.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/README.md +1 -0
- package/dist/kernel-worker.js +1 -1
- package/dist/node-driver-worker.js.map +2 -2
- package/dist/node-process-worker.js +36 -8
- package/dist/node-process-worker.js.map +3 -3
- package/dist/node.js +1 -1
- package/dist/process-worker.js +9 -2
- package/dist/process-worker.js.map +2 -2
- package/dist/types/process/js/js-context.d.ts +7 -0
- package/package.json +1 -1
|
@@ -37,9 +37,15 @@ export interface JsMemory {
|
|
|
37
37
|
external?: number;
|
|
38
38
|
arrayBuffers?: number;
|
|
39
39
|
}
|
|
40
|
+
export interface JsAsyncContext {
|
|
41
|
+
run<R>(store: unknown, fn: (...args: unknown[]) => R, ...args: unknown[]): R;
|
|
42
|
+
getStore(): unknown;
|
|
43
|
+
enterWith(store: unknown): void;
|
|
44
|
+
}
|
|
40
45
|
export interface JsProgramContext {
|
|
41
46
|
readonly kernel: JsKernelInfo;
|
|
42
47
|
memory(): JsMemory;
|
|
48
|
+
readonly asyncContext?: JsAsyncContext;
|
|
43
49
|
readonly argv: readonly string[];
|
|
44
50
|
readonly env: Readonly<Record<string, string>>;
|
|
45
51
|
readonly pid: number;
|
|
@@ -157,6 +163,7 @@ export interface ContextOptions {
|
|
|
157
163
|
strays?: JsStrays;
|
|
158
164
|
thread: JsThreadContext;
|
|
159
165
|
memory?: (() => JsMemory) | undefined;
|
|
166
|
+
asyncContext?: (() => JsAsyncContext) | undefined;
|
|
160
167
|
fs?: {
|
|
161
168
|
owners: boolean;
|
|
162
169
|
links: boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ai-ecoverse/slicc-kernel",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.143.0",
|
|
4
4
|
"description": "SLICC's wasm-realm kernel: run Emscripten programs in the browser against OPFS, with fork, spawn, pipes and waitpid",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "Apache-2.0",
|