Skip to content

Commit e649042

Browse files
committed
Remove f16 const eval crash test
Const eval negation was added. This test is now covered by Miri tests, and merged into an existing UI test. Fixes <#124583>
1 parent 5cb58ad commit e649042

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

tests/crashes/124583.rs

-5
This file was deleted.

tests/ui/numbers-arithmetic/f16-f128-lit.rs

+4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// Make sure negation happens correctly. Also included:
2+
// issue: rust-lang/rust#124583
13
//@ run-pass
24

35
#![feature(f16)]
@@ -8,9 +10,11 @@ fn main() {
810
assert_eq!((-0.0_f16).to_bits(), 0x8000);
911
assert_eq!(10.0_f16.to_bits(), 0x4900);
1012
assert_eq!((-10.0_f16).to_bits(), 0xC900);
13+
assert_eq!((-(-0.0f16)).to_bits(), 0x0000);
1114

1215
assert_eq!(0.0_f128.to_bits(), 0x0000_0000_0000_0000_0000_0000_0000_0000);
1316
assert_eq!((-0.0_f128).to_bits(), 0x8000_0000_0000_0000_0000_0000_0000_0000);
1417
assert_eq!(10.0_f128.to_bits(), 0x4002_4000_0000_0000_0000_0000_0000_0000);
1518
assert_eq!((-10.0_f128).to_bits(), 0xC002_4000_0000_0000_0000_0000_0000_0000);
19+
assert_eq!((-(-0.0f128)).to_bits(), 0x0000_0000_0000_0000_0000_0000_0000_0000);
1620
}

0 commit comments

Comments
 (0)