diff options
| author | Jakub Beránek <berykubik@gmail.com> | 2025-06-18 18:06:50 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-06-18 18:06:50 +0200 |
| commit | fd6b24f1624766d970628032c6e758d800cfa256 (patch) | |
| tree | 2f75635874d3230503edd722e559d7a2664dc12e /compiler/rustc_codegen_llvm/src/llvm_util.rs | |
| parent | 0093ca5c760df11bfab0c9c556addef7b508acbc (diff) | |
| parent | e4f196a7b43db0f35c9bea3956c2ed1ea1a751be (diff) | |
| download | rust-fd6b24f1624766d970628032c6e758d800cfa256.tar.gz rust-fd6b24f1624766d970628032c6e758d800cfa256.zip | |
Rollup merge of #142383 - scottmcm:operandref-builder, r=workingjubilee
CodeGen: rework Aggregate implemention for rvalue_creates_operand cases A non-trivial refactor pulled out from rust-lang/rust#138759 r? workingjubilee The previous implementation I'd written here based on `index_by_increasing_offset` is complicated to follow and difficult to extend to non-structs. This changes the implementation, without actually changing any codegen (thus no test changes either), to be more like the existing `extract_field` (<https://github.com/rust-lang/rust/blob/2b0274c71dba0e24370ebf65593da450e2e91868/compiler/rustc_codegen_ssa/src/mir/operand.rs#L345-L425>) in that it allows setting a particular field directly. Notably I've found this one much easier to get right, in particular because having the `OperandRef<Result<V, Scalar>>` gives a really useful thing to include in ICE messages if something did happen to go wrong.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/llvm_util.rs')
0 files changed, 0 insertions, 0 deletions
