[llvm] 2d92336 - Another stab at making the gold plugin compile again
Benjamin Kramer via llvm-commits
llvm-commits at lists.llvm.org
Tue Jan 28 17:13:00 PST 2020
Author: Benjamin Kramer
Date: 2020-01-29T02:12:53+01:00
New Revision: 2d92336db0087ad295401865d7749d4d1cfe4846
URL: https://github.com/llvm/llvm-project/commit/2d92336db0087ad295401865d7749d4d1cfe4846
DIFF: https://github.com/llvm/llvm-project/commit/2d92336db0087ad295401865d7749d4d1cfe4846.diff
LOG: Another stab at making the gold plugin compile again
Added:
Modified:
llvm/tools/gold/gold-plugin.cpp
Removed:
################################################################################
diff --git a/llvm/tools/gold/gold-plugin.cpp b/llvm/tools/gold/gold-plugin.cpp
index d0d837fb0c79..f68f7183e034 100644
--- a/llvm/tools/gold/gold-plugin.cpp
+++ b/llvm/tools/gold/gold-plugin.cpp
@@ -685,8 +685,8 @@ static void getThinLTOOldAndNewSuffix(std::string &OldSuffix,
options::thinlto_object_suffix_replace.find(";") != StringRef::npos);
StringRef SuffixReplace = options::thinlto_object_suffix_replace;
auto Split = SuffixReplace.split(';');
- OldSuffix = Split.first;
- NewSuffix = Split.second;
+ OldSuffix = std::string(Split.first);
+ NewSuffix = std::string(Split.second);
}
/// Given the original \p Path to an output file, replace any filename
@@ -839,7 +839,9 @@ static void getThinLTOOldAndNewPrefix(std::string &OldPrefix,
std::string &NewPrefix) {
StringRef PrefixReplace = options::thinlto_prefix_replace;
assert(PrefixReplace.empty() || PrefixReplace.find(";") != StringRef::npos);
- std::tie(OldPrefix, NewPrefix) = PrefixReplace.split(';');
+ auto Split = PrefixReplace.split(';');
+ OldPrefix = std::string(Split.first);
+ NewPrefix = std::string(Split.second);
}
/// Creates instance of LTO.
More information about the llvm-commits
mailing list