diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-03-18 00:42:48 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-03-18 00:42:48 +0000 |
commit | 92a524fd47b3e3ee9dcbfca86721eeb7c1672f9f (patch) | |
tree | f5d8b2eb840132b9c4999e23821e06f9d1153867 /clang/tools/CIndex/CXCursor.h | |
parent | 8575110ae188294adaf2ac766cd5427fb99c5e8a (diff) | |
download | bcm5719-llvm-92a524fd47b3e3ee9dcbfca86721eeb7c1672f9f.tar.gz bcm5719-llvm-92a524fd47b3e3ee9dcbfca86721eeb7c1672f9f.zip |
Experimental stab at using relexing to identify preprocessor
directives while annotating tokens in CIndex. This functionality
should probably be factored out of this routine, but we're not there
yet.
llvm-svn: 98786
Diffstat (limited to 'clang/tools/CIndex/CXCursor.h')
-rw-r--r-- | clang/tools/CIndex/CXCursor.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/tools/CIndex/CXCursor.h b/clang/tools/CIndex/CXCursor.h index 934d5e2aebd..aa5d4f3a398 100644 --- a/clang/tools/CIndex/CXCursor.h +++ b/clang/tools/CIndex/CXCursor.h @@ -73,6 +73,12 @@ CXCursor MakeCursorTypeRef(TypeDecl *Type, SourceLocation Loc, ASTUnit *TU); /// and optionally the location where the reference occurred. std::pair<TypeDecl *, SourceLocation> getCursorTypeRef(CXCursor C); +/// \brief Create a preprocessing directive cursor. +CXCursor MakePreprocessingDirectiveCursor(SourceRange Range, ASTUnit *TU); + +/// \brief Unpack a given preprocessing directive to retrieve its source range. +SourceRange getCursorPreprocessingDirective(CXCursor C); + Decl *getCursorDecl(CXCursor Cursor); Expr *getCursorExpr(CXCursor Cursor); Stmt *getCursorStmt(CXCursor Cursor); |