diff options
| author | Matthias Krüger <476013+matthiaskrgr@users.noreply.github.com> | 2025-03-02 22:44:24 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-02 22:44:24 +0100 |
| commit | e8134a3380b3de7228ae4ddd0a5b98733d676e5c (patch) | |
| tree | 3480e2196e5aa499ac01bd42a70a52c5d7dea653 /compiler/rustc_codegen_llvm/src | |
| parent | f47c7e8564a581e262fc4a9f51fbaf89ed3ba7c8 (diff) | |
| parent | 33ee398fdaa849e096e4935dba7cf599b9f6b832 (diff) | |
| download | rust-e8134a3380b3de7228ae4ddd0a5b98733d676e5c.tar.gz rust-e8134a3380b3de7228ae4ddd0a5b98733d676e5c.zip | |
Rollup merge of #137641 - kpreid:dealloc, r=Amanieu
More precisely document `Global::deallocate()`'s safety. There is a subtlety which "other conditions must be upheld by the caller" does not capture: `GlobalAlloc`/`alloc::dealloc()` require that the provided layout will be *equal*, not just that it "fits", the layout used to allocate. This is always true here due to how `allocate()`, `grow()`, and `shrink()` are implemented (they never return a larger allocation than requested), but that is a non-local property of the implementation, so it should be documented explicitly. r? libs `@rustbot` label A-allocators
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
0 files changed, 0 insertions, 0 deletions
