summaryrefslogtreecommitdiffstats
path: root/doc/src/snippets/code
diff options
context:
space:
mode:
authorDavid Boddie <dboddie@trolltech.com>2009-04-01 13:47:08 (GMT)
committerDavid Boddie <dboddie@trolltech.com>2009-04-01 13:47:08 (GMT)
commit5ed526bea6331055941360e01024a1a1af57feed (patch)
tree0d9e081d40557c61b42657dc34f07bf9dc93f17b /doc/src/snippets/code
parentc2ad3b2ab704b751f2900729892099a13ef200a0 (diff)
parentaaf765dfb797da6b72807fad61fd2a1d19187c0c (diff)
downloadQt-5ed526bea6331055941360e01024a1a1af57feed.zip
Qt-5ed526bea6331055941360e01024a1a1af57feed.tar.gz
Qt-5ed526bea6331055941360e01024a1a1af57feed.tar.bz2
Merge branch '4.5' of /home/dboddie/git/qt-45/ into 4.5
Diffstat (limited to 'doc/src/snippets/code')
-rw-r--r--doc/src/snippets/code/src_corelib_global_qglobal.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/doc/src/snippets/code/src_corelib_global_qglobal.cpp b/doc/src/snippets/code/src_corelib_global_qglobal.cpp
index 72663e9..287181a 100644
--- a/doc/src/snippets/code/src_corelib_global_qglobal.cpp
+++ b/doc/src/snippets/code/src_corelib_global_qglobal.cpp
@@ -456,3 +456,11 @@ class MyClass : public QObject
//! [45]
QWidget w = QWidget();
//! [45]
+
+//! [46]
+ // Instead of comparing with 0.0
+ qFuzzyCompare(0.0,1.0e-200); // This will return false
+ // Compare adding 1 to both values will fix the problem
+ qFuzzyCompare(1 + 0.0, 1 + 1.0e-200); // This will return true
+//! [46]
+