forked from qt-creator/qt-creator
C++: Compile fix for MSVC
Change-Id: Ie6399ae95b1dee84dc85fe2e7634c020b312a9a7 Reviewed-by: Przemyslaw Gorszkowski <pgorszkowski@gmail.com> Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
This commit is contained in:
committed by
Nikolai Kosjar
parent
70c9c51e5e
commit
8f988a0a21
2
src/libs/3rdparty/cplusplus/Bind.cpp
vendored
2
src/libs/3rdparty/cplusplus/Bind.cpp
vendored
@@ -483,7 +483,7 @@ bool stringLiteralToInt(const StringLiteral *stringLiteral, int *output)
|
||||
}
|
||||
|
||||
std::stringstream ss(std::string(stringLiteral->chars(), stringLiteral->size()));
|
||||
const bool ok = ss >> *output;
|
||||
const bool ok = !(ss >> *output).fail();
|
||||
if (!ok)
|
||||
*output = 0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user