diff options
Diffstat (limited to 'src/plugins/cpptools')
-rw-r--r-- | src/plugins/cpptools/cppcodeformatter.cpp | 2 | ||||
-rw-r--r-- | src/plugins/cpptools/projectpart.cpp | 1 |
2 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/cpptools/cppcodeformatter.cpp b/src/plugins/cpptools/cppcodeformatter.cpp index 069359d869..fca7998ece 100644 --- a/src/plugins/cpptools/cppcodeformatter.cpp +++ b/src/plugins/cpptools/cppcodeformatter.cpp @@ -1054,6 +1054,8 @@ int CodeFormatter::tokenizeBlock(const QTextBlock &block, bool *endedJoined) features.qtKeywordsEnabled = true; features.cxxEnabled = true; features.objCEnabled = true; + features.cxx11Enabled = true; + features.cxx14Enabled = true; SimpleLexer tokenize; tokenize.setLanguageFeatures(features); diff --git a/src/plugins/cpptools/projectpart.cpp b/src/plugins/cpptools/projectpart.cpp index 4569f231d1..2205fb07b5 100644 --- a/src/plugins/cpptools/projectpart.cpp +++ b/src/plugins/cpptools/projectpart.cpp @@ -38,6 +38,7 @@ void ProjectPart::updateLanguageFeatures() const bool hasCxx = languageVersion >= Utils::LanguageVersion::CXX98; const bool hasQt = hasCxx && qtVersion != NoQt; languageFeatures.cxx11Enabled = languageVersion >= Utils::LanguageVersion::CXX11; + languageFeatures.cxx14Enabled = languageVersion >= Utils::LanguageVersion::CXX14; languageFeatures.cxxEnabled = hasCxx; languageFeatures.c99Enabled = languageVersion >= Utils::LanguageVersion::C99; languageFeatures.objCEnabled = languageExtensions.testFlag(Utils::LanguageExtension::ObjectiveC); |