diff options
author | Zachary Turner <zturner@google.com> | 2017-06-02 19:49:14 +0000 |
---|---|---|
committer | Zachary Turner <zturner@google.com> | 2017-06-02 19:49:14 +0000 |
commit | 92dcdda623326bfd97a5833544e396fa739e2a29 (patch) | |
tree | 26ab0c07be6f8c1f067a59c4091d7a43f19f2fb5 /llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp | |
parent | 3440bc37ffc9221a21e9bae540d410279ced283b (diff) | |
download | llvm-92dcdda623326bfd97a5833544e396fa739e2a29.zip llvm-92dcdda623326bfd97a5833544e396fa739e2a29.tar.gz llvm-92dcdda623326bfd97a5833544e396fa739e2a29.tar.bz2 |
[CodeView] Support CodeView subsections in any order.
Previously we would expect certain subsections to appear
in a certain order because some subsections would reference
other subsections, but in practice we need to support
arbitrary orderings since some object file and PDB file
producers generate them this way. This also paves the
way for supporting Yaml <-> Object File conversion of
CodeView, since Object Files typically have quite a
large number of subsections in their debug info.
Differential Revision: https://reviews.llvm.org/D33807
llvm-svn: 304588
Diffstat (limited to 'llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp')
-rw-r--r-- | llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp b/llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp index b8741eb..2e72242 100644 --- a/llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp +++ b/llvm/lib/DebugInfo/CodeView/DebugStringTableSubsection.cpp @@ -72,7 +72,7 @@ Error DebugStringTableSubsection::commit(BinaryStreamWriter &Writer) const { uint32_t DebugStringTableSubsection::size() const { return Strings.size(); } uint32_t DebugStringTableSubsection::getStringId(StringRef S) const { - auto P = Strings.find(S); - assert(P != Strings.end()); - return P->second; + auto Iter = Strings.find(S); + assert(Iter != Strings.end()); + return Iter->second; } |