diff options
author | Douglas Gregor <dgregor@apple.com> | 2009-12-18 18:53:37 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2009-12-18 18:53:37 +0000 |
commit | ff5ce6eefc7c253ef6edf4d4bfc996fdd82d09aa (patch) | |
tree | fdc221aa0e45746fd32384e472b3446a610bf8d4 /tools | |
parent | eac7c53f16bc12bcd9baac756b6f9bb77b74b0ad (diff) |
Extend code-completion results with the type of each result
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91702 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools')
-rw-r--r-- | tools/CIndex/CIndex.cpp | 4 | ||||
-rw-r--r-- | tools/c-index-test/c-index-test.c | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/tools/CIndex/CIndex.cpp b/tools/CIndex/CIndex.cpp index c4a616689a..9b2355dc0a 100644 --- a/tools/CIndex/CIndex.cpp +++ b/tools/CIndex/CIndex.cpp @@ -1114,6 +1114,8 @@ clang_getCompletionChunkKind(CXCompletionString completion_string, return CXCompletionChunk_Placeholder; case CodeCompletionString::CK_Informative: return CXCompletionChunk_Informative; + case CodeCompletionString::CK_ResultType: + return CXCompletionChunk_ResultType; case CodeCompletionString::CK_CurrentParameter: return CXCompletionChunk_CurrentParameter; case CodeCompletionString::CK_LeftParen: @@ -1161,6 +1163,7 @@ const char *clang_getCompletionChunkText(CXCompletionString completion_string, case CodeCompletionString::CK_LeftAngle: case CodeCompletionString::CK_RightAngle: case CodeCompletionString::CK_Comma: + case CodeCompletionString::CK_ResultType: return (*CCStr)[chunk_number].Text; case CodeCompletionString::CK_Optional: @@ -1194,6 +1197,7 @@ clang_getCompletionChunkCompletionString(CXCompletionString completion_string, case CodeCompletionString::CK_LeftAngle: case CodeCompletionString::CK_RightAngle: case CodeCompletionString::CK_Comma: + case CodeCompletionString::CK_ResultType: return 0; case CodeCompletionString::CK_Optional: diff --git a/tools/c-index-test/c-index-test.c b/tools/c-index-test/c-index-test.c index f3458adda8..33013f3b66 100644 --- a/tools/c-index-test/c-index-test.c +++ b/tools/c-index-test/c-index-test.c @@ -355,6 +355,7 @@ clang_getCompletionChunkKindSpelling(enum CXCompletionChunkKind Kind) { case CXCompletionChunk_LeftAngle: return "LeftAngle"; case CXCompletionChunk_RightAngle: return "RightAngle"; case CXCompletionChunk_Comma: return "Comma"; + case CXCompletionChunk_ResultType: return "ResultType"; } return "Unknown"; |