summaryrefslogtreecommitdiff
path: root/cli/js/globals.ts
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2020-06-21 16:34:43 +0200
committerGitHub <noreply@github.com>2020-06-21 16:34:43 +0200
commit79adc7b000a807caff01a3639b18cb91aef9bd9c (patch)
tree8592baf9a2d88aea7a55f55903739b63bd23fded /cli/js/globals.ts
parent86448fd9aaa9d70078f7928c9ea1d5af2679ea08 (diff)
core: add Deno.core.dispatchByName (#6395)
This commit adds alternate dispatch method to core JS API. "Deno.core.dispatchByName()" works like "Deno.core.dispatch()", but takes op name instead of op id as a first argument.
Diffstat (limited to 'cli/js/globals.ts')
-rw-r--r--cli/js/globals.ts5
1 files changed, 5 insertions, 0 deletions
diff --git a/cli/js/globals.ts b/cli/js/globals.ts
index 09be63315..5746b224f 100644
--- a/cli/js/globals.ts
+++ b/cli/js/globals.ts
@@ -82,6 +82,11 @@ declare global {
control: Uint8Array,
...zeroCopy: ArrayBufferView[]
): Uint8Array | null;
+ dispatchByName(
+ opName: string,
+ control: Uint8Array,
+ ...zeroCopy: ArrayBufferView[]
+ ): Uint8Array | null;
setAsyncHandler(opId: number, cb: (msg: Uint8Array) => void): void;
sharedQueue: {
head(): number;