forked from qt-creator/qt-creator
ClangFormat: Compile fix for MSVC
When vanilla LLVM/Clang is used the #warning statement causes actually an error on MSVC. Change-Id: Id3f36efc1b21d48e52a9c44036b99a5b4d9a0d5c Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -153,10 +153,12 @@ bool ClangFormatPlugin::initialize(const QStringList &arguments, QString *errorS
|
||||
}
|
||||
return true;
|
||||
#else
|
||||
#ifndef Q_CC_MSVC
|
||||
#warning ClangFormat: building dummy plugin due to unmodified Clang, see README.md for more info
|
||||
*errorString = "Disabling ClangFormat plugin as it has not been built against a modified Clang's libFormat."
|
||||
#endif
|
||||
*errorString = QStringLiteral("Disabling ClangFormat plugin as it has not been built against a modified Clang's libFormat."
|
||||
"For more information see the Qt Creator README at "
|
||||
"https://code.qt.io/cgit/qt-creator/qt-creator.git/tree/README.md";
|
||||
"https://code.qt.io/cgit/qt-creator/qt-creator.git/tree/README.md");
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user