public void visitAssignop(JCAssignOp tree) { try { open(prec, TreeInfo.assignopPrec); printExpr(tree.lhs, TreeInfo.assignopPrec + 1); print(" " + operatorName(tree.getTag() - JCTree.ASGOffset) + "= "); printExpr(tree.rhs, TreeInfo.assignopPrec); close(prec, TreeInfo.assignopPrec); } catch (IOException e) { throw new UncheckedIOException(e); } }
public JCTree visitCompoundAssignment(CompoundAssignmentTree node, P p) { JCAssignOp t = (JCAssignOp) node; JCTree lhs = copy(t.lhs, p); JCTree rhs = copy(t.rhs, p); return M.at(t.pos).Assignop(t.getTag(), lhs, rhs); }