From 215ff8df74eebb75f630f922188a8eeee47cd35e Mon Sep 17 00:00:00 2001 From: Mehdi Amini Date: Wed, 5 Oct 2016 01:02:22 +0000 Subject: [PATCH] Use StringRef in DarwinAsmParser (NFC) llvm-svn: 283283 --- llvm/lib/MC/MCParser/DarwinAsmParser.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/llvm/lib/MC/MCParser/DarwinAsmParser.cpp b/llvm/lib/MC/MCParser/DarwinAsmParser.cpp index 37515d9c..063b4a6 100644 --- a/llvm/lib/MC/MCParser/DarwinAsmParser.cpp +++ b/llvm/lib/MC/MCParser/DarwinAsmParser.cpp @@ -37,7 +37,7 @@ class DarwinAsmParser : public MCAsmParserExtension { getParser().addDirectiveHandler(Directive, Handler); } - bool parseSectionSwitch(const char *Segment, const char *Section, + bool parseSectionSwitch(StringRef Segment, StringRef Section, unsigned TAA = 0, unsigned ImplicitAlign = 0, unsigned StubSize = 0); @@ -389,8 +389,7 @@ public: } // end anonymous namespace -bool DarwinAsmParser::parseSectionSwitch(const char *Segment, - const char *Section, +bool DarwinAsmParser::parseSectionSwitch(StringRef Segment, StringRef Section, unsigned TAA, unsigned Align, unsigned StubSize) { if (getLexer().isNot(AsmToken::EndOfStatement)) @@ -700,7 +699,7 @@ bool DarwinAsmParser::parseDirectiveSecureLogUnique(StringRef, SMLoc IDLoc) { if (!OS) { std::error_code EC; auto NewOS = llvm::make_unique( - SecureLogFile, EC, sys::fs::F_Append | sys::fs::F_Text); + StringRef(SecureLogFile), EC, sys::fs::F_Append | sys::fs::F_Text); if (EC) return Error(IDLoc, Twine("can't open secure log file: ") + SecureLogFile + " (" + EC.message() + ")"); -- 2.7.4