File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -78,15 +78,15 @@ impl Buf {
78
78
79
79
pub fn as_slice ( & self ) -> & Slice {
80
80
// Safety: Slice is just a wrapper for Wtf8,
81
- // and as_slice returns &Wtf8. Therefore,
82
- // transmuting &Wtf8 to &Slice is safe.
81
+ // and self.inner. as_slice() returns &Wtf8.
82
+ // Therefore, transmuting &Wtf8 to &Slice is safe.
83
83
unsafe { mem:: transmute ( self . inner . as_slice ( ) ) }
84
84
}
85
85
86
86
pub fn as_mut_slice ( & mut self ) -> & mut Slice {
87
87
// Safety: Slice is just a wrapper for Wtf8,
88
- // and as_mut_slice returns &mut Wtf8. Therefore,
89
- // transmuting &mut Wtf8 to &mut Slice is safe.
88
+ // and self.inner. as_mut_slice() returns &mut Wtf8.
89
+ // Therefore, transmuting &mut Wtf8 to &mut Slice is safe.
90
90
unsafe { mem:: transmute ( self . inner . as_mut_slice ( ) ) }
91
91
}
92
92
You can’t perform that action at this time.
0 commit comments