aboutsummaryrefslogtreecommitdiff
path: root/clang/tools/c-index-test/c-index-test.c
diff options
context:
space:
mode:
authorMitch Phillips <31459023+hctim@users.noreply.github.com>2023-03-29 11:36:44 -0700
committerMitch Phillips <31459023+hctim@users.noreply.github.com>2023-03-29 11:39:44 -0700
commit3be6c4d413f6ccabdcc8205ce73970bf3df162d3 (patch)
tree3874feaed40db46fd89d7a29f92bf3268b64ee63 /clang/tools/c-index-test/c-index-test.c
parent96f028c0a2826c1fe13d126124692ba5470d227a (diff)
downloadllvm-3be6c4d413f6ccabdcc8205ce73970bf3df162d3.zip
llvm-3be6c4d413f6ccabdcc8205ce73970bf3df162d3.tar.gz
llvm-3be6c4d413f6ccabdcc8205ce73970bf3df162d3.tar.bz2
Revert "Revert "Revert ExtractAPI from https://reviews.llvm.org/D146656""
This reverts commit 79116475124112051625b1a0665e35c861bb13fd. Broke the ASan bots. See more information in https://reviews.llvm.org/rG79116475124112051625b1a0665e35c861bb13fd
Diffstat (limited to 'clang/tools/c-index-test/c-index-test.c')
-rw-r--r--clang/tools/c-index-test/c-index-test.c20
1 files changed, 0 insertions, 20 deletions
diff --git a/clang/tools/c-index-test/c-index-test.c b/clang/tools/c-index-test/c-index-test.c
index f116111..448435e 100644
--- a/clang/tools/c-index-test/c-index-test.c
+++ b/clang/tools/c-index-test/c-index-test.c
@@ -3,7 +3,6 @@
#include "clang-c/BuildSystem.h"
#include "clang-c/CXCompilationDatabase.h"
#include "clang-c/CXErrorCode.h"
-#include "clang-c/CXSourceLocation.h"
#include "clang-c/CXString.h"
#include "clang-c/Documentation.h"
#include "clang-c/Index.h"
@@ -4882,21 +4881,6 @@ dispose_index:
return result;
}
-static void inspect_single_symbol_sgf_cursor(CXCursor Cursor) {
- CXSourceLocation CursorLoc;
- CXString SGFData;
- const char *SGF;
- unsigned line, column;
- CursorLoc = clang_getCursorLocation(Cursor);
- clang_getSpellingLocation(CursorLoc, 0, &line, &column, 0);
- printf("%d:%d: ", line, column);
-
- SGFData = clang_getSymbolGraphForCursor(Cursor);
- SGF = clang_getCString(SGFData);
- if (SGF)
- printf("%s\n", SGF);
-}
-
/******************************************************************************/
/* Command line processing. */
/******************************************************************************/
@@ -4956,7 +4940,6 @@ static void print_usage(void) {
" c-index-test -print-usr-file <file>\n");
fprintf(stderr,
" c-index-test -single-symbol-sgfs <symbol filter> {<args>*}\n"
- " c-index-test -single-symbol-sgf-at=<site> {<args>*}\n"
" c-index-test -single-symbol-sgf-for=<usr> {<args>}*\n");
fprintf(stderr,
" c-index-test -write-pch <file> <compiler arguments>\n"
@@ -5093,9 +5076,6 @@ int cindextest_main(int argc, const char **argv) {
else if (argc > 3 && strcmp(argv[1], "-single-symbol-sgfs") == 0)
return perform_test_load_source(argc - 3, argv + 3, argv[2],
PrintSingleSymbolSGFs, NULL);
- else if (argc > 2 && strstr(argv[1], "-single-symbol-sgf-at=") == argv[1])
- return inspect_cursor_at(
- argc, argv, "-single-symbol-sgf-at=", inspect_single_symbol_sgf_cursor);
else if (argc > 2 && strstr(argv[1], "-single-symbol-sgf-for=") == argv[1])
return perform_test_single_symbol_sgf(argv[1], argc - 2, argv + 2);