Remove std::move that was preventing return value optimization.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226356 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Richard Trieu 2015-01-17 00:46:44 +00:00
parent 0553dac91f
commit 6cf3f3fceb
2 changed files with 4 additions and 4 deletions

View File

@ -38,7 +38,7 @@ std::unique_ptr<Module> llvm::parseAssembly(MemoryBufferRef F,
if (parseAssemblyInto(F, *M, Err))
return nullptr;
return std::move(M);
return M;
}
std::unique_ptr<Module> llvm::parseAssemblyFile(StringRef Filename,

View File

@ -1570,11 +1570,11 @@ std::string Node::getVerbatimTag() const {
if (Raw.find_last_of('!') == 0) {
Ret = Doc->getTagMap().find("!")->second;
Ret += Raw.substr(1);
return std::move(Ret);
return Ret;
} else if (Raw.startswith("!!")) {
Ret = Doc->getTagMap().find("!!")->second;
Ret += Raw.substr(2);
return std::move(Ret);
return Ret;
} else {
StringRef TagHandle = Raw.substr(0, Raw.find_last_of('!') + 1);
std::map<StringRef, StringRef>::const_iterator It =
@ -1588,7 +1588,7 @@ std::string Node::getVerbatimTag() const {
setError(Twine("Unknown tag handle ") + TagHandle, T);
}
Ret += Raw.substr(Raw.find_last_of('!') + 1);
return std::move(Ret);
return Ret;
}
}