diff options
| author | Trevor Gross <t.gross35@gmail.com> | 2024-10-12 11:08:42 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-10-12 11:08:42 -0500 |
| commit | 8a86f1dd8c56ffba8df909c84d1908fb462efeba (patch) | |
| tree | c1035dac0b3d113e4ad1847c0ebcc2e522832334 /compiler/rustc_codegen_llvm/src/errors.rs | |
| parent | 63a91db022f8df0ed78bfca4633e6f626eae040d (diff) | |
| parent | 187c8b0ce90eb3a446aa6bd838d6984764479a5a (diff) | |
| download | rust-8a86f1dd8c56ffba8df909c84d1908fb462efeba.tar.gz rust-8a86f1dd8c56ffba8df909c84d1908fb462efeba.zip | |
Rollup merge of #130954 - workingjubilee:stabilize-const-mut-fn, r=RalfJung
Stabilize const `ptr::write*` and `mem::replace`
Since `const_mut_refs` and `const_refs_to_cell` have been stabilized, we may now also stabilize the ability to write to places during const evaluation inside our library API. So, we now propose the `const fn` version of `ptr::write` and its variants. This allows us to also stabilize `mem::replace` and `ptr::replace`.
- const `mem::replace`: https://github.com/rust-lang/rust/issues/83164#issuecomment-2338660862
- const `ptr::write{,_bytes,_unaligned}`: https://github.com/rust-lang/rust/issues/86302#issuecomment-2330275266
Their implementation requires an additional internal stabilization of `const_intrinsic_forget`, which is required for `*::write*` and thus `*::replace`. Thus we const-stabilize the internal intrinsics `forget`, `write_bytes`, and `write_via_move`.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/errors.rs')
0 files changed, 0 insertions, 0 deletions
