Add must_use to futures, deny missing docs (#171)
This commit is contained in:
		
				
					committed by
					
						 Carl Lerche
						Carl Lerche
					
				
			
			
				
	
			
			
			
						parent
						
							24a796da72
						
					
				
				
					commit
					b1d282799b
				
			| @@ -1,3 +1,4 @@ | ||||
| //! HTTP2 client side. | ||||
| use {SendStream, RecvStream, ReleaseCapacity}; | ||||
| use codec::{Codec, RecvError}; | ||||
| use frame::{Headers, Pseudo, Reason, Settings, StreamId}; | ||||
| @@ -14,6 +15,7 @@ use std::io; | ||||
| use std::marker::PhantomData; | ||||
|  | ||||
| /// In progress H2 connection binding | ||||
| #[must_use = "futures do nothing unless polled"] | ||||
| pub struct Handshake<T: AsyncRead + AsyncWrite, B: IntoBuf = Bytes> { | ||||
|     builder: Builder, | ||||
|     inner: MapErr<WriteAll<T, &'static [u8]>, fn(io::Error) -> ::Error>, | ||||
| @@ -26,11 +28,17 @@ pub struct Client<B: IntoBuf> { | ||||
|     pending: Option<proto::StreamKey>, | ||||
| } | ||||
|  | ||||
| /// A future to drive the H2 protocol on a connection. | ||||
| /// | ||||
| /// This must be placed in an executor to ensure proper connection management. | ||||
| #[must_use = "futures do nothing unless polled"] | ||||
| pub struct Connection<T, B: IntoBuf> { | ||||
|     inner: proto::Connection<T, Peer, B>, | ||||
| } | ||||
|  | ||||
| /// A future of an HTTP response. | ||||
| #[derive(Debug)] | ||||
| #[must_use = "futures do nothing unless polled"] | ||||
| pub struct ResponseFuture { | ||||
|     inner: proto::OpaqueStreamRef, | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user