mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Fix highlighting of macro arguments
This commit is contained in:
parent
f638f58c76
commit
f0953b21f0
1 changed files with 6 additions and 3 deletions
|
@ -215,6 +215,7 @@ public class SemanticHighlightingReconciler implements ICReconcilingListener {
|
|||
}
|
||||
IASTNode macroNode= node.getTranslationUnit().selectNodeForLocation(fFilePath, useOffset, macroLength);
|
||||
if (macroNode != null && visitMacro(macroNode, macroLength)) {
|
||||
fMinLocation= useOffset + macroLength;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
@ -291,9 +292,11 @@ public class SemanticHighlightingReconciler implements ICReconcilingListener {
|
|||
return;
|
||||
}
|
||||
int offset= nodeLocation.getNodeOffset();
|
||||
int length= nodeLocation.getNodeLength();
|
||||
if (offset > -1 && length > 0) {
|
||||
addPosition(offset, length, highlighting);
|
||||
if (offset >= fMinLocation) {
|
||||
int length= nodeLocation.getNodeLength();
|
||||
if (offset > -1 && length > 0) {
|
||||
addPosition(offset, length, highlighting);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue