Details
-
Bug
-
Resolution: Done
-
P3: Somewhat important
-
5.6.1
-
None
Description
when compiling with Intel Composer XE 2016 compiler on windows one encounters warning #111 on QString::toWCharArray
Qt\5.6.1\include\QtCore/qstring.h(961): warning #111: statement is unreachable
return toUcs4_helper(d->data(), size(), reinterpret_cast<uint *>(array));
^
there is an attempt to suppress some Microsoft warning, but doesn't suppress ones from Intel.
to suppress Intel's warning can add: QT_WARNING_DISABLE_INTEL(111) // "statement is unreachable"
QT_WARNING_PUSH QT_WARNING_DISABLE_MSVC(4127) // "conditional expression is constant" inline int QString::toWCharArray(wchar_t *array) const { if (sizeof(wchar_t) == sizeof(QChar)) { memcpy(array, d->data(), sizeof(QChar) * size()); return size(); } return toUcs4_helper(d->data(), size(), reinterpret_cast<uint *>(array)); } QT_WARNING_POP