diff --git a/libdevcore/CommonData.h b/libdevcore/CommonData.h index 63a374c30..f587b3533 100644 --- a/libdevcore/CommonData.h +++ b/libdevcore/CommonData.h @@ -55,6 +55,13 @@ template std::set& operator+=(std::set& _a, U const& _b _a.insert(_b.begin(), _b.end()); return _a; } +/// Concatenate the contents of a container onto a set, move variant. +template std::set& operator+=(std::set& _a, U&& _b) +{ + for (auto&& x: _b) + _a.insert(std::move(x)); + return _a; +} /// Concatenate two vectors of elements. template inline std::vector operator+(std::vector const& _a, std::vector const& _b)