[LLD] Rename iDTable -> idTable, NFC
authorReid Kleckner <rnk@google.com>
Mon, 11 May 2020 20:16:25 +0000 (13:16 -0700)
committerReid Kleckner <rnk@google.com>
Tue, 12 May 2020 13:37:39 +0000 (06:37 -0700)
The variable renaming change did not handle this variable well.

lld/COFF/PDB.cpp
lld/COFF/TypeMerger.h

index f005d46..1e45ea7 100644 (file)
@@ -416,7 +416,7 @@ PDBLinker::mergeDebugT(ObjFile *file, CVIndexMap *objectIndexMap) {
       fatal("codeview::mergeTypeAndIdRecords failed: " +
             toString(std::move(err)));
   } else {
-    if (auto err = mergeTypeAndIdRecords(tMerger.iDTable, tMerger.typeTable,
+    if (auto err = mergeTypeAndIdRecords(tMerger.idTable, tMerger.typeTable,
                                          objectIndexMap->tpiMap, types,
                                          file->pchSignature))
       fatal("codeview::mergeTypeAndIdRecords failed: " +
@@ -504,7 +504,7 @@ Expected<const CVIndexMap &> PDBLinker::maybeMergeTypeServerPDB(ObjFile *file) {
 
     // Merge IPI.
     if (maybeIpi) {
-      if (auto err = mergeIdRecords(tMerger.iDTable, indexMap.tpiMap,
+      if (auto err = mergeIdRecords(tMerger.idTable, indexMap.tpiMap,
                                     indexMap.ipiMap, maybeIpi->typeArray()))
         fatal("codeview::mergeIdRecords failed: " + toString(std::move(err)));
     }
@@ -695,7 +695,7 @@ static SymbolKind symbolKind(ArrayRef<uint8_t> recordData) {
 
 /// MSVC translates S_PROC_ID_END to S_END, and S_[LG]PROC32_ID to S_[LG]PROC32
 static void translateIdSymbols(MutableArrayRef<uint8_t> &recordData,
-                               TypeCollection &iDTable) {
+                               TypeCollection &idTable) {
   RecordPrefix *prefix = reinterpret_cast<RecordPrefix *>(recordData.data());
 
   SymbolKind kind = symbolKind(recordData);
@@ -725,7 +725,7 @@ static void translateIdSymbols(MutableArrayRef<uint8_t> &recordData,
     // Note that LF_FUNC_ID and LF_MEMFUNC_ID have the same record layout, and
     // in both cases we just need the second type index.
     if (!ti->isSimple() && !ti->isNoneType()) {
-      CVType funcIdData = iDTable.getType(*ti);
+      CVType funcIdData = idTable.getType(*ti);
       ArrayRef<uint8_t> tiBuf = funcIdData.data().slice(8, 4);
       assert(tiBuf.size() == 4 && "corrupt LF_[MEM]FUNC_ID record");
       *ti = *reinterpret_cast<const TypeIndex *>(tiBuf.data());
index e2cfe66..5629c53 100644 (file)
@@ -20,7 +20,7 @@ namespace coff {
 class TypeMerger {
 public:
   TypeMerger(llvm::BumpPtrAllocator &alloc)
-      : typeTable(alloc), iDTable(alloc), globalTypeTable(alloc),
+      : typeTable(alloc), idTable(alloc), globalTypeTable(alloc),
         globalIDTable(alloc) {}
 
   /// Get the type table or the global type table if /DEBUG:GHASH is enabled.
@@ -34,14 +34,14 @@ public:
   inline llvm::codeview::TypeCollection &getIDTable() {
     if (config->debugGHashes)
       return globalIDTable;
-    return iDTable;
+    return idTable;
   }
 
   /// Type records that will go into the PDB TPI stream.
   llvm::codeview::MergingTypeTableBuilder typeTable;
 
   /// Item records that will go into the PDB IPI stream.
-  llvm::codeview::MergingTypeTableBuilder iDTable;
+  llvm::codeview::MergingTypeTableBuilder idTable;
 
   /// Type records that will go into the PDB TPI stream (for /DEBUG:GHASH)
   llvm::codeview::GlobalTypeTableBuilder globalTypeTable;