This commit is contained in:
oli 2020-11-19 11:41:47 +00:00
parent 173892c776
commit 3d1f676906
2 changed files with 2 additions and 2 deletions

View File

@ -61,7 +61,7 @@ use crate::ptr;
/// More concretely, the following code example is unsound, irrespective of whether your
/// custom allocator allows counting how many allocations have happened.
///
/// ```rust,ignore
/// ```text
/// drop(Box::new(42));
/// let number_of_heap_allocs = /* call private allocator API */;
/// unsafe { std::intrinsics::assume(number_of_heap_allocs > 0); }

View File

@ -100,7 +100,7 @@ pub unsafe trait AllocRef {
/// More concretely, the following code example is unsound, irrespective of whether your
/// custom allocator allows counting how many allocations have happened.
///
/// ```rust,ignore
/// ```text
/// Global::dealloc(Global::alloc(some_layout));
/// let number_of_heap_allocs = /* call private allocator API */;
/// unsafe { std::intrinsics::assume(number_of_heap_allocs > 0); }