aboutsummaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp
diff options
context:
space:
mode:
authorKeith Smiley <keithbsmiley@gmail.com>2022-02-03 19:05:18 +0000
committerKeith Smiley <keithbsmiley@gmail.com>2022-02-03 11:07:14 -0800
commitecf132debcda6b718093d52da6cde2f5e5a7c63a (patch)
tree8ce89ce4394014667427a3b2d1af12734b80ce08 /llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp
parent9ac874ff7f68dab612f3cf6a354d3f5b1dd08370 (diff)
downloadllvm-ecf132debcda6b718093d52da6cde2f5e5a7c63a.zip
llvm-ecf132debcda6b718093d52da6cde2f5e5a7c63a.tar.gz
llvm-ecf132debcda6b718093d52da6cde2f5e5a7c63a.tar.bz2
[llvm-libtool-darwin] Remove var to fix use
This seems to have been moved so the second use is invalid on Linux but not macOS
Diffstat (limited to 'llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp')
-rw-r--r--llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp b/llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp
index a5c664c..8b6b264 100644
--- a/llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp
+++ b/llvm/tools/llvm-libtool-darwin/llvm-libtool-darwin.cpp
@@ -360,9 +360,8 @@ private:
auto *O = dyn_cast<MachOObjectFile>(ObjOrErr->get());
uint32_t FileCPUType, FileCPUSubtype;
- StringRef ArchName = O->getArchTriple().getArchName();
std::tie(FileCPUType, FileCPUSubtype) = MachO::getCPUTypeFromArchitecture(
- MachO::getArchitectureFromName(ArchName));
+ MachO::getArchitectureFromName(O->getArchTriple().getArchName()));
// If -arch_only is specified then skip this file if it doesn't match
// the architecture specified.
@@ -373,7 +372,7 @@ private:
if (!NoWarningForNoSymbols && O->symbols().empty())
WithColor::warning() << "'" + Member.MemberName +
"': has no symbols for architecture " +
- ArchName + "\n";
+ O->getArchTriple().getArchName() + "\n";
uint64_t FileCPUID = getCPUID(FileCPUType, FileCPUSubtype);
Builder.Data.MembersPerArchitecture[FileCPUID].push_back(