ASTPrinter allows setting the ouput to any O-Stream, but that printer creates source-code-like syntax (and is also marked with a FIXME). The nice, colourful, mostly human-readable ASTDumper only works on the standard output, which is not feasible in case a user wants to see the AST of a file through a code navigation/comprehension tool.
This small addition of an overload solves generating a nice colourful AST block for the users of a tool I'm working on, CodeCompass, as opposed to having to duplicate the behaviour of definitions that only exist in the anonymous namespace of implementation TUs related to this module.