@Override
    public void visit(ForStmt n, Void arg) {
        // Collector<CharSequence, ?, String> joiner = Collectors.joining(", ");
        // out.println("ForStmt: "
        // + (extended ? n : n.getInitialization().stream().map(node ->
        // Objects.toString(node)).collect(joiner)) + "; "
        // + n.getCompare()
        // + "; " + n.getUpdate().stream().map(node ->
        // Objects.toString(node)).collect(joiner)
        //
        // );
        super.visit(n, arg);
    }
This is a little hand cranked, perhaps hacked together util to take a Java
file and dump a trace of where the visitor goes. Helpful for debugging and
getting an idea on how to manipulate the AST.
jctools-build/src/main/java/org/jctools/queues/atomic/TraceVisitor.java