]> granicus.if.org Git - clang/commitdiff
[refactor] Fix a clang-tidy warning.
authorHaojian Wu <hokein@google.com>
Mon, 30 Oct 2017 11:17:09 +0000 (11:17 +0000)
committerHaojian Wu <hokein@google.com>
Mon, 30 Oct 2017 11:17:09 +0000 (11:17 +0000)
NFC

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@316895 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Tooling/Refactoring/Rename/RenamingAction.cpp

index 210b45b79ef22ed1a5d67a54e4372eb12428b3e3..695fa553b452ee22b76af67e384b5112791ad8e9 100644 (file)
@@ -77,7 +77,8 @@ RenameOccurrences::initiate(RefactoringRuleContext &Context,
   if (!ND)
     return Context.createDiagnosticError(
         SelectionRange.getBegin(), diag::err_refactor_selection_no_symbol);
-  return RenameOccurrences(getCanonicalSymbolDeclaration(ND), NewName);
+  return RenameOccurrences(getCanonicalSymbolDeclaration(ND),
+                           std::move(NewName));
 }
 
 Expected<AtomicChanges>