From: Olivier Goffart Date: Mon, 18 Jul 2011 13:48:40 +0000 (+0200) Subject: Fix use of C style cast. X-Git-Tag: qt-v5.0.0-alpha1~3970 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=77ed8787ac9ef0f74c2ab6699af3fec434e433e5;p=profile%2Fivi%2Fqtbase.git Fix use of C style cast. Fix the test tst_Moc::oldStyleCasts() (The test make sure moc do not generate old C cast, by compiling the generated code and testing for gcc warning. But if it is present in the public header, the warning will be shown) Change-Id: I2fd3d01e7d78639d97bea021c200afbe2caae85f Reviewed-on: http://codereview.qt.nokia.com/1772 Reviewed-by: Qt Sanity Bot Reviewed-by: Oswald Buddenhagen --- diff --git a/src/corelib/tools/qstring.h b/src/corelib/tools/qstring.h index 45ff002..28c2932 100644 --- a/src/corelib/tools/qstring.h +++ b/src/corelib/tools/qstring.h @@ -185,7 +185,7 @@ public: int capacity() const; inline void reserve(int size); - inline void squeeze() { if (d->size < (int)d->alloc || d->ref != 1) realloc(); d->capacityReserved = false;} + inline void squeeze() { if (d->size < int(d->alloc) || d->ref != 1) realloc(); d->capacityReserved = false;} inline const QChar *unicode() const; inline QChar *data();