1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Bug 344379 - Code Style format error

This commit is contained in:
Anton Leherbauer 2011-08-05 14:19:14 +02:00
parent 35a5ad9dbb
commit dbe4fed550
2 changed files with 19 additions and 1 deletions

View file

@ -2600,7 +2600,7 @@ public class CodeFormatterVisitor extends ASTVisitor implements ICPPASTVisitor,
return formatOverloadedLeftShiftChain(node);
}
Runnable tailFormatter = scribe.takeTailFormatter();
Runnable tailFormatter = endsWithMacroExpansion(node) ? null : scribe.takeTailFormatter();
Alignment expressionAlignment= scribe.createAlignment(
Alignment.BINARY_EXPRESSION,

View file

@ -2494,4 +2494,22 @@ public class CodeFormatterTest extends BaseUITestCase {
assertFormatterResult();
}
//#define A 1
//#define B 2
//#define C 4
//void f(int x, int y) {
// f(A|B|C,5);
// return;
//}
//#define A 1
//#define B 2
//#define C 4
//void f(int x, int y) {
// f(A | B | C, 5);
// return;
//}
public void testMacroInBinaryExpression_Bug344379() throws Exception {
assertFormatterResult();
}
}