CppEditor: Consider symbol occurrences in comments

... when renaming.
For local renaming, we consider only function parameters.

Task-number: QTCREATORBUG-12051
Change-Id: I7948d69f11b97663c9bd747ae6241a82dd9bdd82
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Christian Kandeler
2023-08-23 17:26:02 +02:00
parent 164cb389dc
commit 0a058bb657
28 changed files with 525 additions and 86 deletions

View File

@@ -155,7 +155,7 @@ void TestDeclarationComments::commentsForDecl()
const Symbol * const symbol = finder.find();
QVERIFY(symbol);
const QList<Token> commentTokens = commentsForDeclaration(symbol, m_snapshot, m_textDoc);
const QList<Token> commentTokens = commentsForDeclaration(symbol, m_textDoc, m_cppDoc);
if (expectedCommentPrefix.isEmpty()) {
QVERIFY(commentTokens.isEmpty());
return;