Skip to content

Commit

Permalink
Rollup merge of #107916 - reez12g:issue-107040, r=Amanieu
Browse files Browse the repository at this point in the history
fix comment on Allocator trait

fixes #107040
  • Loading branch information
Noratrieb authored May 30, 2023
2 parents 578bcbc + 000cd9b commit 18c9baf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions library/core/src/alloc/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,9 @@ impl fmt::Display for AllocError {
///
/// # Safety
///
/// * Memory blocks returned from an allocator must point to valid memory and retain their validity
/// until the instance and all of its copies and clones are dropped,
/// * Memory blocks returned from an allocator that are [*currently allocated*] must point to
/// valid memory and retain their validity while they are [*currently allocated*] and at
/// least one of the instance and all of its clones has not been dropped.
///
/// * copying, cloning, or moving the allocator must not invalidate memory blocks returned from this
/// allocator. A copied or cloned allocator must behave like the same allocator, and
Expand Down

0 comments on commit 18c9baf

Please sign in to comment.