From dd156e886b0d0f7d67538539bf7f3624b817d80a Mon Sep 17 00:00:00 2001 From: Aaron O'Mullan Date: Fri, 23 Apr 2021 17:50:45 +0200 Subject: refactor(core): rename send() to opcall() (#10307) I think it's a better fit since recv() was killed and opcall <> syscall (send/recv was too reminiscent of request/response and custom payloads) --- core/examples/hello_world.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'core/examples/hello_world.rs') diff --git a/core/examples/hello_world.rs b/core/examples/hello_world.rs index 3a40ee29a..62d268340 100644 --- a/core/examples/hello_world.rs +++ b/core/examples/hello_world.rs @@ -19,8 +19,8 @@ fn main() { // The second one just transforms some input and returns it to JavaScript. // Register the op for outputting a string to stdout. - // It can be invoked with Deno.core.dispatch and the id this method returns - // or Deno.core.dispatchByName and the name provided. + // It can be invoked with Deno.core.opcall and the id this method returns + // or Deno.core.opSync and the name provided. runtime.register_op( "op_print", // The op_fn callback takes a state object OpState, @@ -72,7 +72,7 @@ Deno.core.ops(); // our op_print op to display the stringified argument. const _newline = new Uint8Array([10]); function print(value) { - Deno.core.dispatchByName('op_print', 0, value.toString(), _newline); + Deno.core.opSync('op_print', value.toString(), _newline); } "#, ) -- cgit v1.2.3