From: Jeffrey Yasskin Date: Mon, 15 Mar 2010 06:59:21 +0000 (+0000) Subject: Don't save a temporary string into a StringRef field. X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=ad181304e1e203bb0a039f7581188afdbc1afb42;p=oota-llvm.git Don't save a temporary string into a StringRef field. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98538 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/MC/MCSectionELF.h b/include/llvm/MC/MCSectionELF.h index 41c17bd8fa1..cdd2f73b348 100644 --- a/include/llvm/MC/MCSectionELF.h +++ b/include/llvm/MC/MCSectionELF.h @@ -39,7 +39,7 @@ class MCSectionELF : public MCSection { protected: MCSectionELF(StringRef Section, unsigned type, unsigned flags, SectionKind K, bool isExplicit) - : MCSection(K), SectionName(Section.str()), Type(type), Flags(flags), + : MCSection(K), SectionName(Section), Type(type), Flags(flags), IsExplicit(isExplicit) {} public: