diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-11-03 02:20:36 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-11-03 02:20:36 +0000 |
commit | b4efaa0a14dd2382aa028c03283b5a7f5345e24d (patch) | |
tree | 788353ee92fb19f82a1b17978c89cd4a9de48ab6 /tools/c-index-test/c-index-test.c | |
parent | dfb332d0081c6641d1dbae6a2aeff757c99cc740 (diff) |
[libclang] Add missing return in clang_getExpansionLocation that resulted in that function
always returning a null file/line/column.
Also add at least one use of clang_getExpansionLocation inside c-index-test that would have
made the tests to catch that.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143606 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/c-index-test/c-index-test.c')
-rw-r--r-- | tools/c-index-test/c-index-test.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/c-index-test/c-index-test.c b/tools/c-index-test/c-index-test.c index b46e3842a0..3bfdeeed2a 100644 --- a/tools/c-index-test/c-index-test.c +++ b/tools/c-index-test/c-index-test.c @@ -340,7 +340,7 @@ static const char* GetCursorSource(CXCursor Cursor) { CXSourceLocation Loc = clang_getCursorLocation(Cursor); CXString source; CXFile file; - clang_getSpellingLocation(Loc, &file, 0, 0, 0); + clang_getExpansionLocation(Loc, &file, 0, 0, 0); source = clang_getFileName(file); if (!clang_getCString(source)) { clang_disposeString(source); |