Skip to content

Commit

Permalink
remove the unused code
Browse files Browse the repository at this point in the history
  • Loading branch information
Rain Jiang authored and ihciah committed Nov 10, 2023
1 parent 98fcb51 commit 7c1efcb
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions service-async/src/boxed.rs
Expand Up @@ -5,8 +5,6 @@ use std::{
pin::Pin,
};

// pub use futures_util::future::LocalBoxFuture;

use crate::{MakeService, Service};

pub struct BoxedService<Request, Response, E> {
Expand Down Expand Up @@ -83,14 +81,11 @@ where
type BoxedFuture<T, E> = Pin<Box<dyn Future<Output = Result<T, E>>>>;

struct ServiceVtable<T, U, E> {
call: unsafe fn(raw: *const (), req: T) -> BoxedFuture<U,E>,
call: unsafe fn(raw: *const (), req: T) -> BoxedFuture<U, E>,
drop: unsafe fn(raw: *const ()),
}

unsafe fn call<R, S>(
svc: *const (),
req: R,
) -> BoxedFuture<S::Response, S::Error>
unsafe fn call<R, S>(svc: *const (), req: R) -> BoxedFuture<S::Response, S::Error>
where
R: 'static,
S: Service<R> + 'static,
Expand Down

0 comments on commit 7c1efcb

Please sign in to comment.