MCReturnStatementsPrettyPrinter extends ExpressionsBasisPrettyPrinter implements MCReturnStatementsVisitor { public String prettyprint(ASTMCReturnStatementsNode a) { getPrinter().clearBuffer(); a.accept(getRealThis()); return getPrinter().getContent(); } MCReturnStatementsPrettyPrinter(IndentPrinter out); IndentPrinter getPrinter(); @Override void handle(ASTReturnStatement a); String prettyprint(ASTMCReturnStatementsNode a); @Override void setRealThis(MCReturnStatementsVisitor realThis); @Override MCReturnStatementsVisitor getRealThis();  }
@Test public void testReturnStatement() throws IOException { Optional<ASTReturnStatement> result = parser.parse_StringReturnStatement("return a ;"); assertFalse(parser.hasErrors()); assertTrue(result.isPresent()); ASTReturnStatement ast = result.get(); String output = prettyPrinter.prettyprint(ast); result = parser.parse_StringReturnStatement(output); assertFalse(parser.hasErrors()); assertTrue(result.isPresent()); assertTrue(ast.deepEquals(result.get())); }