add must_use for Future (#450)

This commit is contained in:
Guanqun Lu
2018-09-04 18:30:57 +08:00
committed by Toralf Wittner
parent 02576eecf1
commit ee9be6f0c9
11 changed files with 14 additions and 0 deletions

View File

@ -519,6 +519,7 @@ pub struct Message {
}
/// Implementation of `Future` that must be driven to completion in order for floodsub to work.
#[must_use = "futures do nothing unless polled"]
pub struct FloodSubFuture {
inner: Box<Future<Item = (), Error = IoError>>,
}