summaryrefslogtreecommitdiffstats
path: root/lldb/unittests/Core
diff options
context:
space:
mode:
authorRaphael Isemann <teemperor@gmail.com>2018-01-22 08:11:29 +0000
committerRaphael Isemann <teemperor@gmail.com>2018-01-22 08:11:29 +0000
commit0b16ef781459a65ad77badf7490c93af775dd38a (patch)
tree7889957a46a20cb2afcf2eee2c388ac9e8924815 /lldb/unittests/Core
parent93eaad7dac4573bbe81ffcebd72a9c03dc055d7d (diff)
downloadbcm5719-llvm-0b16ef781459a65ad77badf7490c93af775dd38a.tar.gz
bcm5719-llvm-0b16ef781459a65ad77badf7490c93af775dd38a.zip
Fix unrepresentable float value in ScalarTest
Summary: float can't represent the given value in the literal, so we get this UB error: `runtime error: 1.23457e+48 is outside the range of representable values of type 'float'`. The test seems to not rely on this specific value, so let's just choose a smaller one that can be represented. Reviewers: uweigand Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D42338 llvm-svn: 323081
Diffstat (limited to 'lldb/unittests/Core')
-rw-r--r--lldb/unittests/Core/ScalarTest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/unittests/Core/ScalarTest.cpp b/lldb/unittests/Core/ScalarTest.cpp
index 692aa8aaf11..fedcd195e4a 100644
--- a/lldb/unittests/Core/ScalarTest.cpp
+++ b/lldb/unittests/Core/ScalarTest.cpp
@@ -31,7 +31,7 @@ TEST(ScalarTest, RightShiftOperator) {
TEST(ScalarTest, GetBytes) {
int a = 0x01020304;
long long b = 0x0102030405060708LL;
- float c = 1234567.89e42;
+ float c = 1234567.89e32;
double d = 1234567.89e42;
char e[16] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16};
char f[32] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
OpenPOWER on IntegriCloud