summaryrefslogtreecommitdiff
path: root/core/ops.rs
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2019-11-17 01:17:47 +0100
committerRy Dahl <ry@tinyclouds.org>2019-11-16 19:17:47 -0500
commit8f9a942cb911ed017eb128e9fbeb6f9a48e69601 (patch)
tree4f56623262f84becac18546d9da3d5d9ce9c8735 /core/ops.rs
parentcb00fd6e988184420f842b1e77ca4cf627d32773 (diff)
Use futures 0.3 API (#3358)
Diffstat (limited to 'core/ops.rs')
-rw-r--r--core/ops.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/core/ops.rs b/core/ops.rs
index cce454348..3a4f51b83 100644
--- a/core/ops.rs
+++ b/core/ops.rs
@@ -3,13 +3,15 @@ pub use crate::libdeno::OpId;
use crate::PinnedBuf;
use futures::Future;
use std::collections::HashMap;
+use std::pin::Pin;
pub type Buf = Box<[u8]>;
-pub type OpAsyncFuture<E> = Box<dyn Future<Item = Buf, Error = E> + Send>;
+pub type OpAsyncFuture<E> =
+ Pin<Box<dyn Future<Output = Result<Buf, E>> + Send>>;
pub(crate) type PendingOpFuture =
- Box<dyn Future<Item = (OpId, Buf), Error = CoreError> + Send>;
+ Pin<Box<dyn Future<Output = Result<(OpId, Buf), CoreError>> + Send>>;
pub type OpResult<E> = Result<Op<E>, E>;