[lld] Remove unused local variables (NFC) (#138470)

This commit is contained in:
Kazu Hirata
2025-05-04 14:14:34 -07:00
committed by GitHub
parent 1812a43a22
commit d3e792cec1
3 changed files with 1 additions and 4 deletions

View File

@@ -475,7 +475,6 @@ static bool equalsPath(StringRef path1, StringRef path2) {
// Find by name an OBJ provided on the command line
PrecompSource *UsePrecompSource::findObjByName(StringRef fileNameOnly) {
SmallString<128> currentPath;
for (auto kv : ctx.precompSourceMappings) {
StringRef currentFileName = sys::path::filename(kv.second->file->getName(),
sys::path::Style::windows);

View File

@@ -2319,8 +2319,7 @@ static void writeArchiveStats(Ctx &ctx) {
os << "members\textracted\tarchive\n";
SmallVector<StringRef, 0> archives;
DenseMap<CachedHashStringRef, unsigned> all, extracted;
DenseMap<CachedHashStringRef, unsigned> extracted;
for (ELFFileBase *file : ctx.objectFiles)
if (file->archiveName.size())
++extracted[CachedHashStringRef(file->archiveName)];

View File

@@ -75,7 +75,6 @@ static std::string toString(const llvm::wasm::WasmLimits &limits) {
}
std::string toString(const WasmTableType &type) {
SmallString<128> ret("");
return "type=" + toString(static_cast<ValType>(type.ElemType)) +
"; limits=[" + toString(type.Limits) + "]";
}