aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Index/annotate-tokens.c
AgeCommit message (Collapse)AuthorFilesLines
2016-11-09[libclang] Fix issue with clang_tokenize and make sure it interprets ↵Argyrios Kyrtzidis1-0/+4
CXSourceRange as half-open character range. Patch provided by Emilio Cobos Álvarez! (https://reviews.llvm.org/D26446) llvm-svn: 286421
2016-06-09Make sizeof and alignof a CXCursor_UnaryExprOlivier Goffart1-3/+3
So we can match sizeof expressions more accurately than with UnexposedExpr Differential Revision: http://reviews.llvm.org/D18081 llvm-svn: 272274
2015-03-13[libclang] During member ref expression visitation, ignore base anonymous ↵Argyrios Kyrtzidis1-1/+16
struct/union fields. Otherwise they will shadow the real field that that we are interested in. rdar://19783938 llvm-svn: 232141
2013-02-13[libclang] Fix annotation of a range where the begin or end locationArgyrios Kyrtzidis1-0/+64
is inside a macro argument. Previously we would give up and not annotate anything in the range. rdar://11891550 llvm-svn: 175062
2013-02-08[libclang] Attribute visitation happens out-of-source-order, make sureArgyrios Kyrtzidis1-1/+27
we annotate properly when there is an attribute and not skip type specs if the attribute is after the declaration. rdar://13129077 llvm-svn: 174689
2013-01-07[libclang] Make token annotation of type/storage qualifiers accurate.Argyrios Kyrtzidis1-1/+1
Previously type/storage qualifiers would not be annotated as the declaration they belonged to. Just use the resulting source range of getRawCursorExtent() which is more correct than what AnnotateTokensWorker::Visit() was adjusting it to. llvm-svn: 171774
2011-10-05Expose more statement, expression, and declaration kinds in libclang,Douglas Gregor1-47/+44
from Manuel Holtgrewe! llvm-svn: 141200
2011-09-12[libclang] For getDeclFromExpr in CIndex.cpp, associate the decl ofArgyrios Kyrtzidis1-3/+3
a DeclRefExpr, MemberExpr, etc. with a CastExpr if it is ImplicitCast, since the implicit cast is the one that is invisible in source code. llvm-svn: 139547
2011-03-16Use ElaboratedType also for C.Abramo Bagnara1-3/+3
llvm-svn: 127755
2011-03-02Force CaseStmt to store its child statements in source-code order,Douglas Gregor1-3/+43
which is important for libclang's token-annotation and where's-my-cursor functionality. Fixes <rdar://problem/9004439>. llvm-svn: 126887
2010-12-17Swap the order of the condition and body of a do-while statement inDouglas Gregor1-1/+22
the AST, so that we visit them in source order. Fixes <rdar://problem/8779113>. llvm-svn: 122062
2010-08-10Teach the libclang cursor visitor to walk into the type informationDouglas Gregor1-1/+14
provided by __builtin_types_compatible_p and __builtin_va_arg expressions, now that Abramo has added proper type-source information to those expressions. llvm-svn: 110681
2010-05-05Rework clang_annotateTokens() to annotate tokens with information that more ↵Ted Kremenek1-39/+39
closely matches clang_getCursor(). Tokens are now annotated with the cursor (for the matching AST element) that most closely encompasses that token. llvm-svn: 103064
2010-02-27Robustify SourceManager::getLocation(), so that it returns anDouglas Gregor1-1/+2
end-of-line source location when given a column number beyond the length of the line, or an end-of-file source location when given a line number beyond the length of the file. Previously, we would return an invalid location. llvm-svn: 97299
2010-02-14c-index-test: Unify and always print half-open extents.Daniel Dunbar1-51/+52
llvm-svn: 96160
2010-01-26Implement clang_annotateTokens(), which associates cursors with eachDouglas Gregor1-12/+12
of the tokens within a raw token stream. This does not even attempt to handle macros yet. llvm-svn: 94561
2010-01-26Introduce a CIndex API for lexing the raw tokens within a given sourceDouglas Gregor1-0/+63
range. The token-annotation function does nothing, yet. llvm-svn: 94551