From f87a07ae201f4546aacabc643df311c6d6a7944b Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Fri, 25 Jul 2014 19:22:51 +0000 Subject: [PATCH] Return a StringRef in getDefaultUniversalArchName. Patch by Stephen Drake. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213964 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/Driver/ToolChain.h | 2 +- lib/Driver/ToolChain.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/clang/Driver/ToolChain.h b/include/clang/Driver/ToolChain.h index c9a6c4b57f..7ee569f8a5 100644 --- a/include/clang/Driver/ToolChain.h +++ b/include/clang/Driver/ToolChain.h @@ -121,7 +121,7 @@ public: /// \brief Provide the default architecture name (as expected by -arch) for /// this toolchain. Note t - std::string getDefaultUniversalArchName() const; + StringRef getDefaultUniversalArchName() const; std::string getTripleString() const { return Triple.getTriple(); diff --git a/lib/Driver/ToolChain.cpp b/lib/Driver/ToolChain.cpp index d2c2d55dfb..65dd4d4e2d 100644 --- a/lib/Driver/ToolChain.cpp +++ b/lib/Driver/ToolChain.cpp @@ -50,7 +50,7 @@ const SanitizerArgs& ToolChain::getSanitizerArgs() const { return *SanitizerArguments.get(); } -std::string ToolChain::getDefaultUniversalArchName() const { +StringRef ToolChain::getDefaultUniversalArchName() const { // In universal driver terms, the arch name accepted by -arch isn't exactly // the same as the ones that appear in the triple. Roughly speaking, this is // an inverse of the darwin::getArchTypeForDarwinArchName() function, but the -- 2.40.0