Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of rust-lang#107955 - RalfJung:ancient-ub, r=jyn514
fix UB in ancient test This seems to go back all the way to the [original version of this test](https://github.com/rust-lang/rust/blob/b9aa9def858cfc66d411972b10ce3d98479acd78/src/test/run-pass/regions-mock-trans.rs) from ten years ago... `@nikomatsakis` trip down memory lane? ;) Clearly deallocation is a form of mutation so doing it to a (pointer derived from a) shared reference cannot be legal. Let's use mutable references instead.
- Loading branch information