From c1ec042a0011eeba2480b892a335ca7804c59180 Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Sun, 19 Apr 2020 23:54:46 -0400 Subject: Modify op dispatcher to include &mut Isolate argument (#4821) - Removes unnecessary RwLock and Rc around the op registry table - Preparation to move resource_table to deno_core::Isolate. - Towards #3453, #4222 --- test_plugin/src/lib.rs | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'test_plugin/src') diff --git a/test_plugin/src/lib.rs b/test_plugin/src/lib.rs index 70ba6d9b2..c88052e9a 100644 --- a/test_plugin/src/lib.rs +++ b/test_plugin/src/lib.rs @@ -13,7 +13,11 @@ fn init(context: &mut dyn PluginInitContext) { } init_fn!(init); -pub fn op_test_sync(data: &[u8], zero_copy: Option) -> Op { +pub fn op_test_sync( + _isolate: &mut deno_core::Isolate, + data: &[u8], + zero_copy: Option, +) -> Op { if let Some(buf) = zero_copy { let data_str = std::str::from_utf8(&data[..]).unwrap(); let buf_str = std::str::from_utf8(&buf[..]).unwrap(); @@ -27,7 +31,11 @@ pub fn op_test_sync(data: &[u8], zero_copy: Option) -> Op { Op::Sync(result_box) } -pub fn op_test_async(data: &[u8], zero_copy: Option) -> Op { +pub fn op_test_async( + _isolate: &mut deno_core::Isolate, + data: &[u8], + zero_copy: Option, +) -> Op { let data_str = std::str::from_utf8(&data[..]).unwrap().to_string(); let fut = async move { if let Some(buf) = zero_copy { -- cgit v1.2.3