[libclang] Avoid having the cursor of an expression "overwrite" the annotation of the
commit5517b89953e3c9276f161ce29831de388bb2573d
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>
Mon, 27 Jun 2011 19:42:20 +0000 (27 19:42 +0000)
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>
Mon, 27 Jun 2011 19:42:20 +0000 (27 19:42 +0000)
tree50c66de16abc1643a32809fc7315150701945a0d
parent3f4be6fb8872942f567166ab8d99c89885f26103
[libclang] Avoid having the cursor of an expression "overwrite" the annotation of the
variable declaration that it belongs to.

This can happen for C++ constructor expressions whose range generally
include the variable declaration, e.g.:

  MyCXXClass foo; // Make sure we don't annotate 'foo' as a CallExpr cursor.

rdar://9124499.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133929 91177308-0d34-0410-b5e6-96231b3b80d8
test/Index/annotate-tokens.cpp
tools/libclang/CIndex.cpp