1
+ #![ deny(
2
+ clippy:: missing_trait_methods,
3
+ reason = "Methods should be forwarded to the underlying type"
4
+ ) ]
5
+
1
6
use crate :: { BufRead , ErrorType , Read , ReadReady , Seek , Write , WriteReady } ;
2
7
use alloc:: boxed:: Box ;
3
8
4
9
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
5
- #[ deny(
6
- clippy:: missing_trait_methods,
7
- reason = "Methods should be forwarded to the underlying type"
8
- ) ]
9
10
impl < T : ?Sized + ErrorType > ErrorType for Box < T > {
10
11
type Error = T :: Error ;
11
12
}
12
13
13
14
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
14
- #[ deny(
15
- clippy:: missing_trait_methods,
16
- reason = "Methods should be forwarded to the underlying type"
17
- ) ]
18
15
impl < T : ?Sized + Read > Read for Box < T > {
19
16
#[ inline]
20
17
fn read ( & mut self , buf : & mut [ u8 ] ) -> Result < usize , Self :: Error > {
@@ -23,10 +20,6 @@ impl<T: ?Sized + Read> Read for Box<T> {
23
20
}
24
21
25
22
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
26
- #[ deny(
27
- clippy:: missing_trait_methods,
28
- reason = "Methods should be forwarded to the underlying type"
29
- ) ]
30
23
impl < T : ?Sized + BufRead > BufRead for Box < T > {
31
24
fn fill_buf ( & mut self ) -> Result < & [ u8 ] , Self :: Error > {
32
25
T :: fill_buf ( self )
@@ -38,10 +31,6 @@ impl<T: ?Sized + BufRead> BufRead for Box<T> {
38
31
}
39
32
40
33
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
41
- #[ deny(
42
- clippy:: missing_trait_methods,
43
- reason = "Methods should be forwarded to the underlying type"
44
- ) ]
45
34
impl < T : ?Sized + Write > Write for Box < T > {
46
35
#[ inline]
47
36
fn write ( & mut self , buf : & [ u8 ] ) -> Result < usize , Self :: Error > {
@@ -55,10 +44,6 @@ impl<T: ?Sized + Write> Write for Box<T> {
55
44
}
56
45
57
46
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
58
- #[ deny(
59
- clippy:: missing_trait_methods,
60
- reason = "Methods should be forwarded to the underlying type"
61
- ) ]
62
47
impl < T : ?Sized + Seek > Seek for Box < T > {
63
48
#[ inline]
64
49
fn seek ( & mut self , pos : crate :: SeekFrom ) -> Result < u64 , Self :: Error > {
@@ -67,10 +52,6 @@ impl<T: ?Sized + Seek> Seek for Box<T> {
67
52
}
68
53
69
54
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
70
- #[ deny(
71
- clippy:: missing_trait_methods,
72
- reason = "Methods should be forwarded to the underlying type"
73
- ) ]
74
55
impl < T : ?Sized + ReadReady > ReadReady for Box < T > {
75
56
#[ inline]
76
57
fn read_ready ( & mut self ) -> Result < bool , Self :: Error > {
@@ -79,10 +60,6 @@ impl<T: ?Sized + ReadReady> ReadReady for Box<T> {
79
60
}
80
61
81
62
#[ cfg_attr( docsrs, doc( cfg( any( feature = "std" , feature = "alloc" ) ) ) ) ]
82
- #[ deny(
83
- clippy:: missing_trait_methods,
84
- reason = "Methods should be forwarded to the underlying type"
85
- ) ]
86
63
impl < T : ?Sized + WriteReady > WriteReady for Box < T > {
87
64
#[ inline]
88
65
fn write_ready ( & mut self ) -> Result < bool , Self :: Error > {
0 commit comments