diff options
author | Benjamin Kramer <benny.kra@googlemail.com> | 2017-05-30 19:36:58 +0000 |
---|---|---|
committer | Benjamin Kramer <benny.kra@googlemail.com> | 2017-05-30 19:36:58 +0000 |
commit | 85938b9f71aadf77a05b1680460e97f35d05f17a (patch) | |
tree | c8cb90272c959db11bc1663016db9c7af4ac6349 /lib/Object/WindowsResource.cpp | |
parent | 26ba02bc31495805105f25015a40e62033d9a298 (diff) |
[Object] Fix pessimizing move.
Returning the Error by value triggers copy elision, the move is more
expensive. Clang rightfully warns about it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@304232 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Object/WindowsResource.cpp')
-rw-r--r-- | lib/Object/WindowsResource.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Object/WindowsResource.cpp b/lib/Object/WindowsResource.cpp index 9dea5539858..c1adb26bd3d 100644 --- a/lib/Object/WindowsResource.cpp +++ b/lib/Object/WindowsResource.cpp @@ -20,7 +20,7 @@ namespace object { #define RETURN_IF_ERROR(X) \ if (auto EC = X) \ - return std::move(EC); + return EC; const uint32_t MIN_HEADER_SIZE = 7 * sizeof(uint32_t) + 2 * sizeof(uint16_t); |