[llvm] r283216 - Remove duplicated typedef. NFC.
Rafael Espindola via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 4 06:09:59 PDT 2016
Author: rafael
Date: Tue Oct 4 08:09:59 2016
New Revision: 283216
URL: http://llvm.org/viewvc/llvm-project?rev=283216&view=rev
Log:
Remove duplicated typedef. NFC.
Modified:
llvm/trunk/lib/MC/StringTableBuilder.cpp
Modified: llvm/trunk/lib/MC/StringTableBuilder.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/MC/StringTableBuilder.cpp?rev=283216&r1=283215&r2=283216&view=diff
==============================================================================
--- llvm/trunk/lib/MC/StringTableBuilder.cpp (original)
+++ llvm/trunk/lib/MC/StringTableBuilder.cpp Tue Oct 4 08:09:59 2016
@@ -86,10 +86,9 @@ void StringTableBuilder::finalizeInOrder
}
void StringTableBuilder::finalizeStringTable(bool Optimize) {
- typedef std::pair<CachedHash<StringRef>, size_t> StringOffsetPair;
- std::vector<StringOffsetPair *> Strings;
+ std::vector<StringPair *> Strings;
Strings.reserve(StringIndexMap.size());
- for (StringOffsetPair &P : StringIndexMap)
+ for (StringPair &P : StringIndexMap)
Strings.push_back(&P);
if (!Strings.empty()) {
@@ -99,7 +98,7 @@ void StringTableBuilder::finalizeStringT
multikey_qsort(&Strings[0], &Strings[0] + Strings.size(), 0);
} else {
std::sort(Strings.begin(), Strings.end(),
- [](const StringOffsetPair *LHS, const StringOffsetPair *RHS) {
+ [](const StringPair *LHS, const StringPair *RHS) {
return LHS->second < RHS->second;
});
}
@@ -120,7 +119,7 @@ void StringTableBuilder::finalizeStringT
}
StringRef Previous;
- for (StringOffsetPair *P : Strings) {
+ for (StringPair *P : Strings) {
StringRef S = P->first.Val;
if (K == WinCOFF)
assert(S.size() > COFF::NameSize && "Short string in COFF string table!");
More information about the llvm-commits
mailing list