I wrote some project using QtCreator 2.5.1 and Qt 4.8.0. I added to *.pro file:
QMAKE_CXXFLAGS += -std=c++0x
And all compiles and works correct, but IDE still highlights C++11-style pieces of code as wrong. E.g. this string:
QVector<int> colwi{100,70,30,40,25,25,25,25,25};
Can this be fixed?
in your qmake .pro file, add
Qt5:
CONFIG += c++11
or Qt4:
CXXFLAGS += -std=c++11
See http://qt-project.org/forums/viewthread/24551
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With