Bug 470977: Formatter Removes Space between Assert and Unary [message #1700764] |
Mon, 06 July 2015 22:01  |
Eclipse User |
|
|
|
This is a bug I would really like to get a fix for, so I have been looking around the source myself to see if I can figure anything out.
This looks like the relevant method:
public boolean visit(AssertStatement assertStatement, BlockScope scope) {
this.scribe.printNextToken(TerminalTokens.TokenNameassert);
this.scribe.space();
assertStatement.assertExpression.traverse(this, scope);
if (assertStatement.exceptionArgument != null) {
this.scribe.printNextToken(TerminalTokens.TokenNameCOLON, this.preferences.insert_space_before_colon_in_assert);
if (this.preferences.insert_space_after_colon_in_assert) {
this.scribe.space();
}
assertStatement.exceptionArgument.traverse(this, scope);
}
this.scribe.printNextToken(TerminalTokens.TokenNameSEMICOLON, this.preferences.insert_space_before_semicolon);
this.scribe.printTrailingComment();
return false;
}
I would like to play around a bit with the code and run some tests on the formatter's behavior, but I can't figure out how to actually run any of the existing tests?
The launcher configuration launches an instance of Eclipse without the ability to create a Java project... so I have no way of running the formatter manually, either.
Are there any devs who have worked on the formatter who might be able to help me out?
|
|
|
|
Powered by
FUDForum. Page generated in 0.02986 seconds