Philip, I've just learned that there's ConstStmtVisitor (but, unfortunately no ConstDeclVisitor), it wouldn't require many const_casts to change dumpDecl/dumpStmt to take const *. http://llvm-reviews.chandlerc.com/D226