From: Martin Boehme Date: Wed, 3 Jun 2020 11:07:13 +0000 (+0200) Subject: [clangd] Add std::move() to a return statement to please some compilers. X-Git-Tag: llvmorg-12-init~4287 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a3220dffcb1da0cfe3e22a336141c76c78d474b7;p=platform%2Fupstream%2Fllvm.git [clangd] Add std::move() to a return statement to please some compilers. This has been causing build errors in Swift CI. Differential Revision: https://reviews.llvm.org/D81079 --- diff --git a/clang-tools-extra/clangd/index/FileIndex.cpp b/clang-tools-extra/clangd/index/FileIndex.cpp index 79ec112..1a18af1 100644 --- a/clang-tools-extra/clangd/index/FileIndex.cpp +++ b/clang-tools-extra/clangd/index/FileIndex.cpp @@ -201,7 +201,8 @@ FileShardedIndex::getShard(llvm::StringRef Uri) const { RelB.insert(*Rel); } IF.Relations = std::move(RelB).build(); - return IF; + // Explicit move here is needed by some compilers. + return std::move(IF); } SlabTuple indexMainDecls(ParsedAST &AST) {