summaryrefslogtreecommitdiffstats
path: root/config.tests/unix/floatmath
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@nokia.com>2009-03-23 09:18:55 (GMT)
committerSimon Hausmann <simon.hausmann@nokia.com>2009-03-23 09:18:55 (GMT)
commite5fcad302d86d316390c6b0f62759a067313e8a9 (patch)
treec2afbf6f1066b6ce261f14341cf6d310e5595bc1 /config.tests/unix/floatmath
downloadQt-e5fcad302d86d316390c6b0f62759a067313e8a9.zip
Qt-e5fcad302d86d316390c6b0f62759a067313e8a9.tar.gz
Qt-e5fcad302d86d316390c6b0f62759a067313e8a9.tar.bz2
Long live Qt 4.5!
Diffstat (limited to 'config.tests/unix/floatmath')
-rw-r--r--config.tests/unix/floatmath/floatmath.cpp17
-rw-r--r--config.tests/unix/floatmath/floatmath.pro3
2 files changed, 20 insertions, 0 deletions
diff --git a/config.tests/unix/floatmath/floatmath.cpp b/config.tests/unix/floatmath/floatmath.cpp
new file mode 100644
index 0000000..126f820
--- /dev/null
+++ b/config.tests/unix/floatmath/floatmath.cpp
@@ -0,0 +1,17 @@
+#include <math.h>
+
+int main(int argc, char **argv)
+{
+ float c = ceilf(1.3f);
+ float f = floorf(1.7f);
+ float s = sinf(3.8);
+ float t = cosf(7.3);
+ float u = sqrtf(8.4);
+ float l = logf(9.2);
+
+ if (c == 1.0f && f == 2.0f && s == 3.0f && t == 4.0f && u == 5.0f && l == 6.0f)
+ return 0;
+ else
+ return 1;
+}
+
diff --git a/config.tests/unix/floatmath/floatmath.pro b/config.tests/unix/floatmath/floatmath.pro
new file mode 100644
index 0000000..4c78563
--- /dev/null
+++ b/config.tests/unix/floatmath/floatmath.pro
@@ -0,0 +1,3 @@
+SOURCES = floatmath.cpp
+CONFIG -= x11 qt
+