We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d4559c0 commit 1c1b789Copy full SHA for 1c1b789
library/core/tests/fmt/num.rs
@@ -152,8 +152,11 @@ fn test_format_int_exp_precision() {
152
assert_eq!(format!("{:+10.3e}", 1), " +1.000e0");
153
154
// test precision remains correct when rounding to next power
155
-
156
- for i in i16::MIN..=i16::MAX {
+ #[cfg(miri)] // can't cover all of `i16` in Miri
+ let range = [i16::MIN, -1, 1, i16::MAX];
157
+ #[cfg(not(miri))]
158
+ let range = i16::MIN..=i16::MAX;
159
+ for i in range {
160
for p in 0..=5 {
161
assert_eq!(
162
format!("{i:.p$e}"),
0 commit comments