Commit c0cb9812 authored by Jason Prado's avatar Jason Prado Committed by facebook-github-bot-1

Remove superfluous std::move calls

Summary: clang-3.7 upstream warns that these calls prevent a copy elision
(-Wpessimizing-move).

Reviewed By: @​mzlee

Differential Revision: D2366951
parent e9a78a18
...@@ -363,8 +363,8 @@ class IPAddress : boost::totally_ordered<IPAddress> { ...@@ -363,8 +363,8 @@ class IPAddress : boost::totally_ordered<IPAddress> {
* @return IPAddress instance with bits set to 0 * @return IPAddress instance with bits set to 0
*/ */
IPAddress mask(uint8_t numBits) const { IPAddress mask(uint8_t numBits) const {
return isV4() ? IPAddress(std::move(asV4().mask(numBits))) return isV4() ? IPAddress(asV4().mask(numBits))
: IPAddress(std::move(asV6().mask(numBits))); : IPAddress(asV6().mask(numBits));
} }
/** /**
......
...@@ -180,7 +180,7 @@ class IPAddressV4 : boost::totally_ordered<IPAddressV4> { ...@@ -180,7 +180,7 @@ class IPAddressV4 : boost::totally_ordered<IPAddressV4> {
ByteArray4 toByteArray() const { ByteArray4 toByteArray() const {
ByteArray4 ba{{0}}; ByteArray4 ba{{0}};
std::memcpy(ba.data(), bytes(), 4); std::memcpy(ba.data(), bytes(), 4);
return std::move(ba); return ba;
} }
// @see IPAddress#toFullyQualified // @see IPAddress#toFullyQualified
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment