mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Use forward_tuple to prevent needless copies
This commit is contained in:
@@ -42,8 +42,8 @@ public:
|
||||
void add (std::string const& method, handler_type&& handler)
|
||||
{
|
||||
std::pair <Map::iterator, bool> result (m_map.emplace (
|
||||
std::piecewise_construct, std::make_tuple (method),
|
||||
std::make_tuple (std::move (handler))));
|
||||
std::piecewise_construct, std::forward_as_tuple (method),
|
||||
std::forward_as_tuple (std::move (handler))));
|
||||
}
|
||||
|
||||
bool dispatch (Request& req)
|
||||
|
||||
Reference in New Issue
Block a user