[ASTMatchers] Don't assert-fail in specifiesTypeLoc().
authorDavid L. Jones <dlj@google.com>
Mon, 18 Jun 2018 08:59:16 +0000 (08:59 +0000)
committerDavid L. Jones <dlj@google.com>
Mon, 18 Jun 2018 08:59:16 +0000 (08:59 +0000)
commit8f7adcd7fb1fd1a01a0de79eca954c49e7e3dabb
tree39d86c8ac2c3291dabd19ebf6e04c2338c3fef2a
parent068246886a78a3fcfd7237f2dfae1b21c80a4480
[ASTMatchers] Don't assert-fail in specifiesTypeLoc().

The specifiesTypeLoc() matcher narrows a nestedNameSpecifier matcher based on a
typeloc within the NNS. However, the matcher does not guard against NNS which
are a namespace, and cause getTypeLoc to assert-fail.

llvm-svn: 334929
clang/include/clang/ASTMatchers/ASTMatchers.h
clang/unittests/ASTMatchers/ASTMatchersNodeTest.cpp