forked from qt-creator/qt-creator
Add system include path to HeaderPath and merge ProjectPartHeaderPath
System include paths are appended after other includes by the compiler. So we should set them as system includes and not as normal includes. Otherwise we change the include order. Headers in system include paths are not cluttering the screen with unwanted warning and by the way improve performance too. ProjectPartHeaderPath was a dopperganger of HeaderPath, so we merged them. Change-Id: I7c394b4098b697de79761499ffcd5913cc02d652 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -24,8 +24,9 @@
|
||||
****************************************************************************/
|
||||
|
||||
#include "cppeditortestcase.h"
|
||||
#include "cppquickfix.h"
|
||||
|
||||
#include <cpptools/projectpartheaderpath.h>
|
||||
#include <projectexplorer/headerpath.h>
|
||||
|
||||
#include <QByteArray>
|
||||
#include <QList>
|
||||
@@ -76,8 +77,8 @@ public:
|
||||
/// Exactly one QuickFixTestDocument must contain the cursor position marker '@'
|
||||
/// or "@{start}" and "@{end}"
|
||||
BaseQuickFixTestCase(const QList<QuickFixTestDocument::Ptr> &testDocuments,
|
||||
const CppTools::ProjectPartHeaderPaths &headerPaths
|
||||
= CppTools::ProjectPartHeaderPaths());
|
||||
const ProjectExplorer::HeaderPaths &headerPaths
|
||||
= ProjectExplorer::HeaderPaths());
|
||||
|
||||
~BaseQuickFixTestCase();
|
||||
|
||||
@@ -91,7 +92,7 @@ private:
|
||||
CppTools::CppCodeStylePreferences *m_cppCodeStylePreferences;
|
||||
QByteArray m_cppCodeStylePreferencesOriginalDelegateId;
|
||||
|
||||
CppTools::ProjectPartHeaderPaths m_headerPathsToRestore;
|
||||
ProjectExplorer::HeaderPaths m_headerPathsToRestore;
|
||||
bool m_restoreHeaderPaths;
|
||||
};
|
||||
|
||||
@@ -101,8 +102,8 @@ class QuickFixOperationTest : public BaseQuickFixTestCase
|
||||
public:
|
||||
QuickFixOperationTest(const QList<QuickFixTestDocument::Ptr> &testDocuments,
|
||||
CppQuickFixFactory *factory,
|
||||
const CppTools::ProjectPartHeaderPaths &headerPaths
|
||||
= CppTools::ProjectPartHeaderPaths(),
|
||||
const ProjectExplorer::HeaderPaths &headerPaths
|
||||
= ProjectExplorer::HeaderPaths(),
|
||||
int operationIndex = 0,
|
||||
const QByteArray &expectedFailMessage = QByteArray());
|
||||
|
||||
@@ -118,8 +119,8 @@ class QuickFixOfferedOperationsTest : public BaseQuickFixTestCase
|
||||
public:
|
||||
QuickFixOfferedOperationsTest(const QList<QuickFixTestDocument::Ptr> &testDocuments,
|
||||
CppQuickFixFactory *factory,
|
||||
const CppTools::ProjectPartHeaderPaths &headerPaths
|
||||
= CppTools::ProjectPartHeaderPaths(),
|
||||
const ProjectExplorer::HeaderPaths &headerPaths
|
||||
= ProjectExplorer::HeaderPaths(),
|
||||
const QStringList &expectedOperations = QStringList());
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user