I don't think using the AST directly for control flow is something that will always work. The static analyzer builds a CFG for that reason. http://reviews.llvm.org/D5105