aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
diff options
context:
space:
mode:
authorMitch Phillips <31459023+hctim@users.noreply.github.com>2023-03-29 11:35:59 -0700
committerMitch Phillips <31459023+hctim@users.noreply.github.com>2023-03-29 11:39:32 -0700
commit96f028c0a2826c1fe13d126124692ba5470d227a (patch)
treedc2b6d0221823823a740000590bbadcbc42866f2 /clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
parent477f9cea77e6d55ecddaafbedccd418750c40dbd (diff)
downloadllvm-96f028c0a2826c1fe13d126124692ba5470d227a.zip
llvm-96f028c0a2826c1fe13d126124692ba5470d227a.tar.gz
llvm-96f028c0a2826c1fe13d126124692ba5470d227a.tar.bz2
Revert "[clang][ExtractAPI] Add queried symbol to parent contexts in libclang"
This reverts commit 1cfe1e732ad8e8148f6fa8fc0f0c86f4b965d567. Depends on reverted commit 158a431227a876306fe5838936413dd51588d0c6. See https://reviews.llvm.org/rG79116475124112051625b1a0665e35c861bb13fd for more information, this broke the ASan bots.
Diffstat (limited to 'clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp')
-rw-r--r--clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp b/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
index 7676c74..8a98f5c 100644
--- a/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
+++ b/clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp
@@ -547,6 +547,10 @@ Array generateParentContexts(const RecordTy &Record, const APISet &API,
serializeParentContext(PC, Lang));
});
+ // The last component would be the record itself so let's remove it.
+ if (!ParentContexts.empty())
+ ParentContexts.pop_back();
+
return ParentContexts;
}