Fix uses of the C99 PRI format macros not to conflict with C++11 UDLs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152474 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Benjamin Kramer
2012-03-10 02:04:38 +00:00
parent ff0275ea53
commit 51cf866163
3 changed files with 14 additions and 13 deletions

View File

@@ -204,7 +204,8 @@ static void SortAndPrintSymbolList() {
strcpy(SymbolSizeStr, " ");
if (i->Address != object::UnknownAddressOrSize)
format("%08"PRIx64, i->Address).print(SymbolAddrStr, sizeof(SymbolAddrStr));
format("%08" PRIx64, i->Address).print(SymbolAddrStr,
sizeof(SymbolAddrStr));
if (i->Size != object::UnknownAddressOrSize)
format("%08" PRIx64, i->Size).print(SymbolSizeStr, sizeof(SymbolSizeStr));

View File

@@ -327,8 +327,8 @@ static void DisassembleObject(const ObjectFile *Obj, bool InlineRelocs) {
if (error(rel_cur->getTypeName(name))) goto skip_print_rel;
if (error(rel_cur->getValueString(val))) goto skip_print_rel;
outs() << format("\t\t\t%8"PRIx64": ", SectionAddr + addr) << name << "\t"
<< val << "\n";
outs() << format("\t\t\t%8" PRIx64 ": ", SectionAddr + addr) << name
<< "\t" << val << "\n";
skip_print_rel:
++rel_cur;
@@ -388,8 +388,8 @@ static void PrintSectionHeaders(const ObjectFile *o) {
if (error(si->isBSS(BSS))) return;
std::string Type = (std::string(Text ? "TEXT " : "") +
(Data ? "DATA " : "") + (BSS ? "BSS" : ""));
outs() << format("%3d %-13s %09"PRIx64" %017"PRIx64" %s\n", i, Name.str().c_str(), Size,
Address, Type.c_str());
outs() << format("%3d %-13s %09" PRIx64 " %017" PRIx64 " %s\n",
i, Name.str().c_str(), Size, Address, Type.c_str());
++i;
}
}