rust/compiler/rustc_const_eval/src
Matthias Krüger 2fd3007cbc
Rollup merge of #130514 - compiler-errors:unsafe-binders, r=oli-obk
Implement MIR lowering for unsafe binders

This is the final bit of the unsafe binders puzzle. It implements MIR, CTFE, and codegen for unsafe binders, and enforces that (for now) they are `Copy`. Later on, I'll introduce a new trait that relaxes this requirement to being "is `Copy` or `ManuallyDrop<T>`" which more closely models how we treat union fields.

Namely, wrapping unsafe binders is now `Rvalue::WrapUnsafeBinder`, which acts much like an `Rvalue::Aggregate`. Unwrapping unsafe binders are implemented as a MIR projection `ProjectionElem::UnwrapUnsafeBinder`, which acts much like `ProjectionElem::Field`.

Tracking:
- https://github.com/rust-lang/rust/issues/130516
2025-02-01 16:41:03 +01:00
..
check_consts Rollup merge of #130514 - compiler-errors:unsafe-binders, r=oli-obk 2025-02-01 16:41:03 +01:00
const_eval Auto merge of #134424 - 1c3t3a:null-checks, r=saethlin 2025-01-31 15:56:53 +00:00
interpret Rollup merge of #130514 - compiler-errors:unsafe-binders, r=oli-obk 2025-02-01 16:41:03 +01:00
util Begin to implement type system layer of unsafe binders 2024-12-22 21:57:57 +00:00
errors.rs Implement MIR const trait stability checks 2025-01-28 05:01:12 +00:00
lib.rs introduce ty::Value 2025-01-30 17:47:44 +01:00