Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Move llvm:Error types
Older compilers don't have the copy-elision of newer C++ compilers,
resulting in an error message when returning a non-copyable type. Move
llvm::Error instead of copying it.
  • Loading branch information
etcwilde committed Oct 17, 2023
commit 6608235b0d93ac36867658aa8a4e441a0be691dc
4 changes: 2 additions & 2 deletions lib/Frontend/CachingUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ Expected<bool> cas::CachedResultLoader::replay(CallbackTy Callback) {
[&](swift::cas::CompileJobCacheResult::Output Output) -> Error {
return Callback(Output.Kind, Output.Object);
}))
return Err;
return std::move(Err);

return true;
}
Expand Down Expand Up @@ -120,7 +120,7 @@ Expected<bool> cas::CachedResultLoader::replay(CallbackTy Callback) {
"Unexpected output kind in clang cached result");
return Callback(OutputKind, Output.Object);
}))
return Err;
return std::move(Err);

return true;
}
Expand Down