[llvm] 45fa936 - [ObjectYAML][DWARF] Remove unused context. NFC.
Xing GUO via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 23 08:58:40 PDT 2020
Author: Xing GUO
Date: 2020-06-24T00:02:51+08:00
New Revision: 45fa936855f62dc7864028a3f2fa7a9693b9fceb
URL: https://github.com/llvm/llvm-project/commit/45fa936855f62dc7864028a3f2fa7a9693b9fceb
DIFF: https://github.com/llvm/llvm-project/commit/45fa936855f62dc7864028a3f2fa7a9693b9fceb.diff
LOG: [ObjectYAML][DWARF] Remove unused context. NFC.
The context is unused. This patch helps remove it.
Reviewed By: jhenderson
Differential Revision: https://reviews.llvm.org/D82351
Added:
Modified:
llvm/lib/ObjectYAML/DWARFYAML.cpp
Removed:
################################################################################
diff --git a/llvm/lib/ObjectYAML/DWARFYAML.cpp b/llvm/lib/ObjectYAML/DWARFYAML.cpp
index 37177263b568..9865c1b6294b 100644
--- a/llvm/lib/ObjectYAML/DWARFYAML.cpp
+++ b/llvm/lib/ObjectYAML/DWARFYAML.cpp
@@ -48,8 +48,6 @@ SetVector<StringRef> DWARFYAML::Data::getUsedSectionNames() const {
namespace yaml {
void MappingTraits<DWARFYAML::Data>::mapping(IO &IO, DWARFYAML::Data &DWARF) {
- auto oldContext = IO.getContext();
- IO.setContext(&DWARF);
IO.mapOptional("debug_str", DWARF.DebugStrings);
IO.mapOptional("debug_abbrev", DWARF.AbbrevDecls);
if (!DWARF.ARanges.empty() || !IO.outputting())
@@ -63,7 +61,6 @@ void MappingTraits<DWARFYAML::Data>::mapping(IO &IO, DWARFYAML::Data &DWARF) {
IO.mapOptional("debug_info", DWARF.CompileUnits);
IO.mapOptional("debug_line", DWARF.DebugLines);
IO.mapOptional("debug_addr", DWARF.DebugAddr);
- IO.setContext(&oldContext);
}
void MappingTraits<DWARFYAML::Abbrev>::mapping(IO &IO,
More information about the llvm-commits
mailing list