@@ -80,7 +80,7 @@ macro_rules! cstr {
80
80
/// It can eventually be converted back into the object. This is used to store objects as pointers
81
81
/// in kernel data structures, for example, an implementation of [`FileOperations`] in `struct
82
82
/// file::private_data`.
83
- pub trait PointerWrapper < T > {
83
+ pub trait PointerWrapper {
84
84
/// Returns the raw pointer.
85
85
fn into_pointer ( self ) -> * const T ;
86
86
@@ -92,7 +92,7 @@ pub trait PointerWrapper<T> {
92
92
unsafe fn from_pointer ( ptr : * const T ) -> Self ;
93
93
}
94
94
95
- impl < T > PointerWrapper < T > for Box < T > {
95
+ impl < T > PointerWrapper for Box < T > {
96
96
fn into_pointer ( self ) -> * const T {
97
97
Box :: into_raw ( self )
98
98
}
@@ -102,7 +102,7 @@ impl<T> PointerWrapper<T> for Box<T> {
102
102
}
103
103
}
104
104
105
- impl < T : RefCounted > PointerWrapper < T > for Ref < T > {
105
+ impl < T : RefCounted > PointerWrapper for Ref < T > {
106
106
fn into_pointer ( self ) -> * const T {
107
107
Ref :: into_raw ( self )
108
108
}
@@ -112,7 +112,7 @@ impl<T: RefCounted> PointerWrapper<T> for Ref<T> {
112
112
}
113
113
}
114
114
115
- impl < T > PointerWrapper < T > for Arc < T > {
115
+ impl < T > PointerWrapper for Arc < T > {
116
116
fn into_pointer ( self ) -> * const T {
117
117
Arc :: into_raw ( self )
118
118
}
@@ -122,7 +122,7 @@ impl<T> PointerWrapper<T> for Arc<T> {
122
122
}
123
123
}
124
124
125
- impl < T , W : PointerWrapper < T > + Deref > PointerWrapper < T > for Pin < W > {
125
+ impl < T , W : PointerWrapper + Deref > PointerWrapper for Pin < W > {
126
126
fn into_pointer ( self ) -> * const T {
127
127
// SAFETY: We continue to treat the pointer as pinned by returning just a pointer to it to
128
128
// the caller.
0 commit comments