[llvm] [llvm][DebugInfo][DWARF] Use formatv() instead of format() (PR #191308)
Sergei Barannikov via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 13 08:44:09 PDT 2026
================
@@ -69,32 +69,32 @@ static void printOperand(raw_ostream &OS, const DIDumpOptions &DumpOpts,
break;
case CFIProgram::OT_FactoredCodeOffset: // Always Unsigned
if (P.codeAlign())
- OS << format(" %" PRId64, Operand * P.codeAlign());
+ OS << formatv(" {0}", Operand * P.codeAlign());
else
- OS << format(" %" PRId64 "*code_alignment_factor", Operand);
+ OS << formatv(" {0}*code_alignment_factor", Operand);
if (Address && P.codeAlign()) {
*Address += Operand * P.codeAlign();
- OS << format(" to 0x%" PRIx64, *Address);
+ OS << formatv(" to {0:x+}", *Address);
}
break;
case CFIProgram::OT_SignedFactDataOffset:
if (P.dataAlign())
- OS << format(" %" PRId64, int64_t(Operand) * P.dataAlign());
+ OS << formatv(" {0}", int64_t(Operand) * P.dataAlign());
else
- OS << format(" %" PRId64 "*data_alignment_factor", int64_t(Operand));
+ OS << formatv(" {0}*data_alignment_factor", int64_t(Operand));
break;
case CFIProgram::OT_UnsignedFactDataOffset:
if (P.dataAlign())
- OS << format(" %" PRId64, Operand * P.dataAlign());
+ OS << formatv(" {0:d}", int64_t(Operand * P.dataAlign()));
----------------
s-barannikov wrote:
Thanks, I got it
https://github.com/llvm/llvm-project/pull/191308
More information about the llvm-commits
mailing list