[lld] r252745 - Convert a few size_t I missed in the previous commit. Sorry about that.

Rafael Espindola via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 11 07:55:01 PST 2015


Author: rafael
Date: Wed Nov 11 09:55:00 2015
New Revision: 252745

URL: http://llvm.org/viewvc/llvm-project?rev=252745&view=rev
Log:
Convert a few size_t I missed in the previous commit. Sorry about that.

Modified:
    lld/trunk/ELF/InputSection.cpp

Modified: lld/trunk/ELF/InputSection.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/InputSection.cpp?rev=252745&r1=252744&r2=252745&view=diff
==============================================================================
--- lld/trunk/ELF/InputSection.cpp (original)
+++ lld/trunk/ELF/InputSection.cpp Wed Nov 11 09:55:00 2015
@@ -170,7 +170,7 @@ MergeInputSection<ELFT>::getOffset(uintX
   // Find the element this offset points to.
   auto I = std::upper_bound(
       Offsets.begin(), Offsets.end(), Offset,
-      [](const uintX_t &A, const std::pair<uintX_t, size_t> &B) {
+      [](const uintX_t &A, const std::pair<uintX_t, uintX_t> &B) {
         return A < B.first;
       });
   uintX_t End = I == Offsets.end() ? Data.size() : I->first;
@@ -180,7 +180,7 @@ MergeInputSection<ELFT>::getOffset(uintX
   // Compute the Addend and if the Base is cached, return.
   uintX_t Addend = Offset - Start;
   uintX_t &Base = I->second;
-  if (Base != size_t(-1))
+  if (Base != uintX_t(-1))
     return Base + Addend;
 
   // Map the base to the offset in the output section and cashe it.




More information about the llvm-commits mailing list