Skip to content

Commit ac5f1c2

Browse files
committed
Temporarily allow missing safety doc lint
Signed-off-by: Nico Burns <[email protected]>
1 parent dd3e844 commit ac5f1c2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

malloc_size_of/src/lib.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,6 +152,7 @@ impl MallocSizeOfOps {
152152

153153
/// Call `size_of_op` on `ptr`, first checking that the allocation isn't
154154
/// empty, because some types (such as `Vec`) utilize empty allocations.
155+
#[allow(clippy::missing_safety_doc)]
155156
pub unsafe fn malloc_size_of<T: ?Sized>(&self, ptr: *const T) -> usize {
156157
if MallocSizeOfOps::is_empty(ptr) {
157158
0
@@ -167,6 +168,7 @@ impl MallocSizeOfOps {
167168

168169
/// Call `enclosing_size_of_op`, which must be available, on `ptr`, which
169170
/// must not be empty.
171+
#[allow(clippy::missing_safety_doc)]
170172
pub unsafe fn malloc_enclosing_size_of<T>(&self, ptr: *const T) -> usize {
171173
assert!(!MallocSizeOfOps::is_empty(ptr));
172174
(self.enclosing_size_of_op.unwrap())(ptr as *const c_void)

0 commit comments

Comments
 (0)