diff options
| author | bors <bors@rust-lang.org> | 2024-05-20 18:04:19 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2024-05-20 18:04:19 +0000 |
| commit | be71fd477243f253a735bb35e0cd23cc528cf30a (patch) | |
| tree | c9e82040cf28f18b0cbd9f0187b7d4b0dea5ecdd /tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff | |
| parent | 474bee7bf540db9344ca975298b6c1646a74b772 (diff) | |
| parent | 1640225b9d15da64e6af922b4dc3573b337138d0 (diff) | |
Auto merge of #125331 - matthiaskrgr:rollup-4kfrh4n, r=matthiaskrgr
Rollup of 7 pull requests Successful merges: - #124682 (Suggest setting lifetime in borrowck error involving types with elided lifetimes) - #124917 (Check whether the next_node is else-less if in get_return_block) - #125106 (coverage: Memoize and simplify counter expressions) - #125173 (Remove `Rvalue::CheckedBinaryOp`) - #125305 (add some codegen tests for issue 120493) - #125314 ( Add an experimental feature gate for global registration) - #125318 (Migrate `run-make/rustdoc-scrape-examples-whitespace` to `rmake.rs`) r? `@ghost` `@rustbot` modify labels: rollup
Diffstat (limited to 'tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff')
| -rw-r--r-- | tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff b/tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff index b35538f8972..53663c6476b 100644 --- a/tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff +++ b/tests/mir-opt/dataflow-const-prop/checked.main.DataflowConstProp.panic-abort.diff @@ -40,7 +40,7 @@ + _4 = const 1_i32; StorageLive(_5); - _5 = _2; -- _6 = CheckedAdd(_4, _5); +- _6 = AddWithOverflow(_4, _5); - assert(!move (_6.1: bool), "attempt to compute `{} + {}`, which would overflow", move _4, move _5) -> [success: bb1, unwind unreachable]; + _5 = const 2_i32; + _6 = const (3_i32, false); @@ -57,7 +57,7 @@ StorageLive(_8); StorageLive(_9); - _9 = _7; -- _10 = CheckedAdd(_9, const 1_i32); +- _10 = AddWithOverflow(_9, const 1_i32); - assert(!move (_10.1: bool), "attempt to compute `{} + {}`, which would overflow", move _9, const 1_i32) -> [success: bb2, unwind unreachable]; + _9 = const i32::MAX; + _10 = const (i32::MIN, true); |
