Skip to content

Commit

Permalink
[flang] Remove needless std::move() that breaks clang build
Browse files Browse the repository at this point in the history
Add the std::move() to where it should have been

Original-commit: flang-compiler/f18@54fe9b3
Reviewed-on: flang-compiler/f18#903
  • Loading branch information
klausler committed Jan 3, 2020
1 parent 004b841 commit 2e32cad
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions flang/lib/semantics/semantics.cc
Expand Up @@ -209,22 +209,22 @@ void SemanticsContext::CheckDoVarRedefine(const parser::CharBlock &location,
if (IsActiveDoVariable(*root)) {
parser::CharBlock doLoc{GetDoVariableLocation(*root)};
CHECK(doLoc != parser::CharBlock{});
Say(location, message, root->name())
Say(location, std::move(message), root->name())
.Attach(doLoc, "Enclosing DO construct"_en_US);
}
}
}

void SemanticsContext::WarnDoVarRedefine(
const parser::CharBlock &location, const Symbol &variable) {
CheckDoVarRedefine(location, variable,
std::move("Possible redefinition of DO variable '%s'"_en_US));
CheckDoVarRedefine(
location, variable, "Possible redefinition of DO variable '%s'"_en_US);
}

void SemanticsContext::CheckDoVarRedefine(
const parser::CharBlock &location, const Symbol &variable) {
CheckDoVarRedefine(location, variable,
std::move("Cannot redefine DO variable '%s'"_err_en_US));
CheckDoVarRedefine(
location, variable, "Cannot redefine DO variable '%s'"_err_en_US);
}

void SemanticsContext::CheckDoVarRedefine(const parser::Variable &variable) {
Expand Down

0 comments on commit 2e32cad

Please sign in to comment.