[llvm] f48d9e9 - [nfc] Ignoring unused values (#125695)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Feb 6 06:28:05 PST 2025
Author: natanelh-mobileye
Date: 2025-02-06T09:28:01-05:00
New Revision: f48d9e95d4ccd6ad2a7f53eb9db3e439c40c9dbf
URL: https://github.com/llvm/llvm-project/commit/f48d9e95d4ccd6ad2a7f53eb9db3e439c40c9dbf
DIFF: https://github.com/llvm/llvm-project/commit/f48d9e95d4ccd6ad2a7f53eb9db3e439c40c9dbf.diff
LOG: [nfc] Ignoring unused values (#125695)
trying to avoid `unused variable` warning under gcc7
Added:
Modified:
llvm/include/llvm/ADT/StableHashing.h
Removed:
################################################################################
diff --git a/llvm/include/llvm/ADT/StableHashing.h b/llvm/include/llvm/ADT/StableHashing.h
index b220a0ed1f9131a..b6bd23c6945bf99 100644
--- a/llvm/include/llvm/ADT/StableHashing.h
+++ b/llvm/include/llvm/ADT/StableHashing.h
@@ -54,14 +54,13 @@ inline stable_hash stable_hash_combine(stable_hash A, stable_hash B,
// maintain closeness to the original name across
diff erent builds.
inline StringRef get_stable_name(StringRef Name) {
// Return the part after ".content." that represents contents.
- auto [P0, S0] = Name.rsplit(".content.");
+ StringRef S0 = Name.rsplit(".content.").second;
if (!S0.empty())
return S0;
// Ignore these suffixes.
- auto [P1, S1] = Name.rsplit(".llvm.");
- auto [P2, S2] = P1.rsplit(".__uniq.");
- return P2;
+ StringRef P1 = Name.rsplit(".llvm.").first;
+ return P1.rsplit(".__uniq.").first;
}
// Generates a consistent hash value for a given input name across
diff erent
More information about the llvm-commits
mailing list