[llvm] r185766 - COFFDumper: Print uint64_t with the right format string.

Benjamin Kramer benny.kra at googlemail.com
Sat Jul 6 13:01:46 PDT 2013


Author: d0k
Date: Sat Jul  6 15:01:46 2013
New Revision: 185766

URL: http://llvm.org/viewvc/llvm-project?rev=185766&view=rev
Log:
COFFDumper: Print uint64_t with the right format string.

I wish we could typecheck llvm::format.

Modified:
    llvm/trunk/tools/llvm-readobj/COFFDumper.cpp

Modified: llvm/trunk/tools/llvm-readobj/COFFDumper.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-readobj/COFFDumper.cpp?rev=185766&r1=185765&r2=185766&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-readobj/COFFDumper.cpp (original)
+++ llvm/trunk/tools/llvm-readobj/COFFDumper.cpp Sat Jul  6 15:01:46 2013
@@ -479,15 +479,15 @@ static std::string formatSymbol(const st
 
   StringRef Sym;
   if (resolveSymbolName(Rels, Offset, Sym)) {
-    Str << format(" (0x%X)", Offset);
+    Str << format(" (0x%" PRIX64 ")", Offset);
     return Str.str();
   }
 
   Str << Sym;
   if (Disp > 0) {
-    Str << format(" +0x%X (0x%X)", Disp, Offset);
+    Str << format(" +0x%X (0x%" PRIX64 ")", Disp, Offset);
   } else {
-    Str << format(" (0x%X)", Offset);
+    Str << format(" (0x%" PRIX64 ")", Offset);
   }
 
   return Str.str();





More information about the llvm-commits mailing list