diff options
Diffstat (limited to 'core/ops_builtin.rs')
-rw-r--r-- | core/ops_builtin.rs | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/core/ops_builtin.rs b/core/ops_builtin.rs index 14d8c6e39..a742a77b1 100644 --- a/core/ops_builtin.rs +++ b/core/ops_builtin.rs @@ -40,7 +40,7 @@ pub(crate) fn init_builtins() -> Extension { } #[op] -pub fn void_op_sync(_: &mut OpState, _: (), _: ()) -> Result<(), Error> { +pub fn void_op_sync(_: &mut OpState) -> Result<(), Error> { Ok(()) } @@ -57,8 +57,6 @@ pub async fn void_op_async( #[op] pub fn op_resources( state: &mut OpState, - _: (), - _: (), ) -> Result<Vec<(ResourceId, String)>, Error> { let serialized_resources = state .resource_table @@ -69,16 +67,12 @@ pub fn op_resources( } #[op] -pub fn op_void_sync(_state: &mut OpState, _: (), _: ()) -> Result<(), Error> { +pub fn op_void_sync(_state: &mut OpState) -> Result<(), Error> { Ok(()) } #[op] -pub async fn op_void_async( - _state: Rc<RefCell<OpState>>, - _: (), - _: (), -) -> Result<(), Error> { +pub async fn op_void_async(_state: Rc<RefCell<OpState>>) -> Result<(), Error> { Ok(()) } @@ -87,7 +81,6 @@ pub async fn op_void_async( pub fn op_close( state: &mut OpState, rid: Option<ResourceId>, - _: (), ) -> Result<(), Error> { // TODO(@AaronO): drop Option after improving type-strictness balance in // serde_v8 @@ -102,7 +95,6 @@ pub fn op_close( pub fn op_try_close( state: &mut OpState, rid: Option<ResourceId>, - _: (), ) -> Result<(), Error> { // TODO(@AaronO): drop Option after improving type-strictness balance in // serde_v8. @@ -114,8 +106,6 @@ pub fn op_try_close( #[op] pub fn op_metrics( state: &mut OpState, - _: (), - _: (), ) -> Result<(OpMetrics, Vec<OpMetrics>), Error> { let aggregate = state.tracker.aggregate(); let per_op = state.tracker.per_op(); @@ -229,7 +219,6 @@ async fn op_write( async fn op_shutdown( state: Rc<RefCell<OpState>>, rid: ResourceId, - _: (), ) -> Result<(), Error> { let resource = state.borrow().resource_table.get_any(rid)?; resource.shutdown().await |