[llvm] cf3a6c8 - [llvm][DebugInfo] formatv in LVCodeViewVisitor (#192010)
via llvm-commits
llvm-commits at lists.llvm.org
Tue Apr 14 03:16:49 PDT 2026
Author: Konrad Kleine
Date: 2026-04-14T12:16:44+02:00
New Revision: cf3a6c8431f9a5b91f9faa77384a70029745dce8
URL: https://github.com/llvm/llvm-project/commit/cf3a6c8431f9a5b91f9faa77384a70029745dce8
DIFF: https://github.com/llvm/llvm-project/commit/cf3a6c8431f9a5b91f9faa77384a70029745dce8.diff
LOG: [llvm][DebugInfo] formatv in LVCodeViewVisitor (#192010)
This relates to #35980.
Added:
Modified:
llvm/lib/DebugInfo/LogicalView/Readers/LVCodeViewVisitor.cpp
Removed:
################################################################################
diff --git a/llvm/lib/DebugInfo/LogicalView/Readers/LVCodeViewVisitor.cpp b/llvm/lib/DebugInfo/LogicalView/Readers/LVCodeViewVisitor.cpp
index 3818dc3b9a026..fddb39733b048 100644
--- a/llvm/lib/DebugInfo/LogicalView/Readers/LVCodeViewVisitor.cpp
+++ b/llvm/lib/DebugInfo/LogicalView/Readers/LVCodeViewVisitor.cpp
@@ -410,7 +410,7 @@ void LVNamespaceDeduction::init() {
};
Header();
for (const StringRef &Item : Container)
- dbgs() << formatv("'{0}'\n", Item.str().c_str());
+ dbgs() << formatv("'{0}'\n", Item);
};
Print(DeducedScopes, "Deducted Scopes");
@@ -422,7 +422,7 @@ void LVNamespaceDeduction::init() {
LVScope *LVNamespaceDeduction::get(LVStringRefs Components) {
LLVM_DEBUG({
for (const StringRef &Component : Components)
- dbgs() << formatv("'{0}'\n", Component.str().c_str());
+ dbgs() << formatv("'{0}'\n", Component);
});
if (Components.empty())
@@ -457,8 +457,7 @@ LVScope *LVNamespaceDeduction::get(StringRef ScopedName, bool CheckScope) {
return Iter == IdentifiedNamespaces.end();
});
- LLVM_DEBUG(
- { dbgs() << formatv("ScopedName: '{0}'\n", ScopedName.str().c_str()); });
+ LLVM_DEBUG({ dbgs() << formatv("ScopedName: '{0}'\n", ScopedName); });
return get(Components);
}
@@ -3456,7 +3455,7 @@ void LVLogicalVisitor::printRecords(raw_ostream &OS) const {
OS << "\n";
}
};
- OS << format("%20s", Name.str().c_str());
+ OS << formatv("{0,20}", Name);
NewLine();
};
More information about the llvm-commits
mailing list