Add a version of getSymbol with an explicit symbol table. Use it. NFC.
[oota-llvm.git] / include / llvm / Object / ELFYAML.h
index b45507920a9c61af52fd32f2bbb8c923f5f679f7..df0aa500c8a29d6b552a3432a02ad2a9335a0722 100644 (file)
@@ -85,7 +85,13 @@ struct SectionOrType {
 };
 
 struct Section {
-  enum class SectionKind { Group, RawContent, Relocation, MipsABIFlags };
+  enum class SectionKind {
+    Group,
+    RawContent,
+    Relocation,
+    NoBits,
+    MipsABIFlags
+  };
   SectionKind Kind;
   StringRef Name;
   ELF_SHT Type;
@@ -106,6 +112,14 @@ struct RawContentSection : Section {
   }
 };
 
+struct NoBitsSection : Section {
+  llvm::yaml::Hex64 Size;
+  NoBitsSection() : Section(SectionKind::NoBits) {}
+  static bool classof(const Section *S) {
+    return S->Kind == SectionKind::NoBits;
+  }
+};
+
 struct Group : Section {
   // Members of a group contain a flag and a list of section indices
   // that are part of the group.