forked from qt-creator/qt-creator
Clang: Rename HighlightingMark to TokenInfo
Before adding additional members into that class it makes sense to rename it to better represent its content. Other classes serving the same purpose are also renamed to keep the names consistent. Change-Id: I3c8517e42aae29779d71ec9c85b713cff581a473 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
#include "clangdiagnostictooltipwidget.h"
|
||||
#include "clangfixitoperation.h"
|
||||
#include "clangfixitoperationsextractor.h"
|
||||
#include "clanghighlightingmarksreporter.h"
|
||||
#include "clangtokeninfosreporter.h"
|
||||
#include "clangprojectsettings.h"
|
||||
#include "clangutils.h"
|
||||
|
||||
@@ -225,14 +225,14 @@ toTextEditorBlocks(QTextDocument *textDocument,
|
||||
}
|
||||
}
|
||||
|
||||
const QVector<ClangBackEnd::HighlightingMarkContainer>
|
||||
&ClangEditorDocumentProcessor::highlightingMarks() const
|
||||
const QVector<ClangBackEnd::TokenInfoContainer>
|
||||
&ClangEditorDocumentProcessor::tokenInfos() const
|
||||
{
|
||||
return m_highlightingMarks;
|
||||
return m_tokenInfos;
|
||||
}
|
||||
|
||||
void ClangEditorDocumentProcessor::updateHighlighting(
|
||||
const QVector<ClangBackEnd::HighlightingMarkContainer> &highlightingMarks,
|
||||
const QVector<ClangBackEnd::TokenInfoContainer> &tokenInfos,
|
||||
const QVector<ClangBackEnd::SourceRangeContainer> &skippedPreprocessorRanges,
|
||||
uint documentRevision)
|
||||
{
|
||||
@@ -240,10 +240,10 @@ void ClangEditorDocumentProcessor::updateHighlighting(
|
||||
const auto skippedPreprocessorBlocks = toTextEditorBlocks(textDocument(), skippedPreprocessorRanges);
|
||||
emit ifdefedOutBlocksUpdated(documentRevision, skippedPreprocessorBlocks);
|
||||
|
||||
m_highlightingMarks = highlightingMarks;
|
||||
m_tokenInfos = tokenInfos;
|
||||
m_semanticHighlighter.setHighlightingRunner(
|
||||
[highlightingMarks]() {
|
||||
auto *reporter = new HighlightingMarksReporter(highlightingMarks);
|
||||
[tokenInfos]() {
|
||||
auto *reporter = new TokenInfosReporter(tokenInfos);
|
||||
return reporter->start();
|
||||
});
|
||||
m_semanticHighlighter.run();
|
||||
|
||||
Reference in New Issue
Block a user