aboutsummaryrefslogtreecommitdiff
path: root/src/park/either.rs
diff options
context:
space:
mode:
authorJoel Galenson <jgalenson@google.com>2020-10-23 09:39:31 -0700
committerJoel Galenson <jgalenson@google.com>2020-10-23 09:52:09 -0700
commitd5495b03381a3ebe0805db353d198b285b535b5c (patch)
tree778b8524d15fca8b73db0253ee0e1919d0848bb6 /src/park/either.rs
parentba45c5bedf31df8562364c61d3dfb5262f10642e (diff)
downloadtokio-d5495b03381a3ebe0805db353d198b285b535b5c.tar.gz
Update to tokio-0.3.1 and add new features
Test: Build Change-Id: I5b5b9b386a21982a019653d0cf0bd3afc505cfac
Diffstat (limited to 'src/park/either.rs')
-rw-r--r--src/park/either.rs9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/park/either.rs b/src/park/either.rs
index 67f1e17..ee02ec1 100644
--- a/src/park/either.rs
+++ b/src/park/either.rs
@@ -1,3 +1,5 @@
+#![cfg_attr(not(feature = "full"), allow(dead_code))]
+
use crate::park::{Park, Unpark};
use std::fmt;
@@ -36,6 +38,13 @@ where
Either::B(b) => b.park_timeout(duration).map_err(Either::B),
}
}
+
+ fn shutdown(&mut self) {
+ match self {
+ Either::A(a) => a.shutdown(),
+ Either::B(b) => b.shutdown(),
+ }
+ }
}
impl<A, B> Unpark for Either<A, B>