@@ -9,13 +9,13 @@ use pin_utils::unsafe_pinned;
9
9
/// Future for the [`copy_into`](super::AsyncReadExt::copy_into) method.
10
10
#[ derive( Debug ) ]
11
11
#[ must_use = "futures do nothing unless you `.await` or poll them" ]
12
- pub struct CopyInto < ' a , R : AsyncRead , W > {
12
+ pub struct CopyInto < ' a , R : AsyncRead , W : ? Sized > {
13
13
inner : CopyBufInto < ' a , BufReader < R > , W > ,
14
14
}
15
15
16
- impl < ' a , R : AsyncRead , W > Unpin for CopyInto < ' a , R , W > where CopyBufInto < ' a , BufReader < R > , W > : Unpin { }
16
+ impl < ' a , R : AsyncRead , W : ? Sized > Unpin for CopyInto < ' a , R , W > where CopyBufInto < ' a , BufReader < R > , W > : Unpin { }
17
17
18
- impl < ' a , R : AsyncRead , W > CopyInto < ' a , R , W > {
18
+ impl < ' a , R : AsyncRead , W : ? Sized > CopyInto < ' a , R , W > {
19
19
unsafe_pinned ! ( inner: CopyBufInto <' a, BufReader <R >, W >) ;
20
20
21
21
pub ( super ) fn new ( reader : R , writer : & mut W ) -> CopyInto < ' _ , R , W > {
@@ -25,7 +25,7 @@ impl<'a, R: AsyncRead, W> CopyInto<'a, R, W> {
25
25
}
26
26
}
27
27
28
- impl < R : AsyncRead , W : AsyncWrite + Unpin > Future for CopyInto < ' _ , R , W > {
28
+ impl < R : AsyncRead , W : AsyncWrite + Unpin + ? Sized > Future for CopyInto < ' _ , R , W > {
29
29
type Output = io:: Result < u64 > ;
30
30
31
31
fn poll ( self : Pin < & mut Self > , cx : & mut Context < ' _ > ) -> Poll < Self :: Output > {
0 commit comments