Remove copy of current const prop tests and add a few new tests
This commit is contained in:
parent
1f82a9f89e
commit
da4a40f816
106 changed files with 253 additions and 2500 deletions
8
src/test/mir-opt/dataflow-const-prop/inherit_overflow.rs
Normal file
8
src/test/mir-opt/dataflow-const-prop/inherit_overflow.rs
Normal file
|
@ -0,0 +1,8 @@
|
|||
// compile-flags: -Coverflow-checks=off -Zunsound-mir-opts
|
||||
|
||||
// EMIT_MIR inherit_overflow.main.DataflowConstProp.diff
|
||||
fn main() {
|
||||
// After inlining, this will contain a `CheckedBinaryOp`. The overflow
|
||||
// must be ignored by the constant propagation to avoid triggering a panic.
|
||||
let _ = <u8 as std::ops::Add>::add(255, 1);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue