angelgarcia added a comment. How can Lexer::getSourceText give us the range? My problem precisely is that I couldn't find any way to obtain the range of the constructor call without the template arguments. http://reviews.llvm.org/D13166