aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAndrew Kelley <superjoe30@gmail.com>2016-01-31 21:50:41 -0700
committerAndrew Kelley <superjoe30@gmail.com>2016-01-31 21:50:41 -0700
commit2e092e08f4fefa3fcd05484a755db5f5eef8e9cd (patch)
tree2ce0b959b66f4a7475531615c00c6fef0a2a27b1 /test
parent675de74412e6006ee270fdd2a3b3e20727328af0 (diff)
downloadzig-2e092e08f4fefa3fcd05484a755db5f5eef8e9cd.tar.gz
zig-2e092e08f4fefa3fcd05484a755db5f5eef8e9cd.zip
fix invalid const expr eval for negative floats
Diffstat (limited to 'test')
-rw-r--r--test/run_tests.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/run_tests.cpp b/test/run_tests.cpp
index 39cecb72d5..5d61da6cd1 100644
--- a/test/run_tests.cpp
+++ b/test/run_tests.cpp
@@ -1497,10 +1497,10 @@ export fn main(argc: c_int, argv: &&u8) -> c_int {
const x: f64 = small;
const y = i32(x);
const z = f64(y);
- printf(c"%.2f\n%d\n%.2f\n", x, y, z);
+ printf(c"%.2f\n%d\n%.2f\n%.2f\n", x, y, z, f64(-0.4));
return 0;
}
- )SOURCE", "3.25\n3\n3.00\n");
+ )SOURCE", "3.25\n3\n3.00\n-0.40\n");
}