Don't break inside array type.
@@ -31,10 +31,12 @@ public class ArrayType extends AbstractType {
@Override
void doFormatOutputExpr(FormattingContext ctx) {
+ try (FormattingContext buffer = ctx.buffer()) {
if (readonly) {
- ctx.append("readonly ");
+ buffer.append("readonly ");
+ }
+ buffer.appendOutputExpression(simpleType).append("[]");
}
- ctx.appendOutputExpression(simpleType).append("[]");
}
@Override
