mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Cosmetics.
This commit is contained in:
parent
e48f239398
commit
59db3eea48
1 changed files with 2 additions and 5 deletions
|
@ -70,15 +70,13 @@ public class ASTNodeSelector implements IASTNodeSelector {
|
||||||
}
|
}
|
||||||
if (lengthInFile > 0) {
|
if (lengthInFile > 0) {
|
||||||
sequenceLength= fLocationResolver.getSequenceNumberForFileOffset(fFilePath, offsetInFile+lengthInFile-1) + 1 - sequenceNumber;
|
sequenceLength= fLocationResolver.getSequenceNumberForFileOffset(fFilePath, offsetInFile+lengthInFile-1) + 1 - sequenceNumber;
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
sequenceLength= 0;
|
sequenceLength= 0;
|
||||||
if (offsetInFile > 0) {
|
if (offsetInFile > 0) {
|
||||||
altSequenceNumber= fLocationResolver.getSequenceNumberForFileOffset(fFilePath, offsetInFile-1);
|
altSequenceNumber= fLocationResolver.getSequenceNumberForFileOffset(fFilePath, offsetInFile-1);
|
||||||
if (altSequenceNumber+1 == sequenceNumber) {
|
if (altSequenceNumber+1 == sequenceNumber) {
|
||||||
altSequenceNumber= -1;
|
altSequenceNumber= -1;
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
// we are on a context boundary and we need to check the variant to the left and
|
// we are on a context boundary and we need to check the variant to the left and
|
||||||
// the one to the right
|
// the one to the right
|
||||||
sequenceLength= 1;
|
sequenceLength= 1;
|
||||||
|
@ -168,5 +166,4 @@ public class ASTNodeSelector implements IASTNodeSelector {
|
||||||
public IASTPreprocessorMacroExpansion findEnclosingMacroExpansion(int offset, int length) {
|
public IASTPreprocessorMacroExpansion findEnclosingMacroExpansion(int offset, int length) {
|
||||||
return findNode(offset, length, Relation.ENCLOSING, IASTPreprocessorMacroExpansion.class);
|
return findNode(offset, length, Relation.ENCLOSING, IASTPreprocessorMacroExpansion.class);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
Loading…
Add table
Reference in a new issue