Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added missing std::move #377

Merged
merged 1 commit into from
May 28, 2023
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion Source/SocketIOLib/Private/internal/sio_client_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ namespace sio
string query_str_value = encode_query_string(it->second);
query_str.append(query_str_value);
}
m_query_string = move(query_str);
m_query_string = std::move(query_str);

m_http_headers = headers;
m_auth = auth;
Expand Down
16 changes: 8 additions & 8 deletions Source/SocketIOLib/Public/sio_message.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ namespace sio
}

string_message(std::string&& v)
:message(flag_string),_v(move(v))
:message(flag_string),_v(std::move(v))
{
}
public:
Expand All @@ -216,7 +216,7 @@ namespace sio

static message::ptr create(std::string&& v)
{
return ptr(new string_message(move(v)));
return ptr(new string_message(std::move(v)));
}

std::string const& get_string() const
Expand Down Expand Up @@ -270,7 +270,7 @@ namespace sio

void push(std::string&& text)
{
_v.push_back(string_message::create(move(text)));
_v.push_back(string_message::create(std::move(text)));
}

void push(std::shared_ptr<std::string> const& binary)
Expand All @@ -297,7 +297,7 @@ namespace sio

void insert(size_t pos,std::string&& text)
{
_v.insert(_v.begin()+pos, string_message::create(move(text)));
_v.insert(_v.begin()+pos, string_message::create(std::move(text)));
}

void insert(size_t pos,std::shared_ptr<std::string> const& binary)
Expand Down Expand Up @@ -362,7 +362,7 @@ namespace sio

void insert(const std::string & key,std::string&& text)
{
_v[key] = string_message::create(move(text));
_v[key] = string_message::create(std::move(text));
}

void insert(const std::string & key,std::shared_ptr<std::string> const& binary)
Expand Down Expand Up @@ -462,7 +462,7 @@ namespace sio

list(std::string&& text)
{
m_vector.push_back(string_message::create(move(text)));
m_vector.push_back(string_message::create(std::move(text)));
}

list(std::shared_ptr<std::string> const& binary)
Expand Down Expand Up @@ -490,7 +490,7 @@ namespace sio

void push(std::string&& text)
{
m_vector.push_back(string_message::create(move(text)));
m_vector.push_back(string_message::create(std::move(text)));
}

void push(std::shared_ptr<std::string> const& binary)
Expand All @@ -517,7 +517,7 @@ namespace sio

void insert(size_t pos,std::string&& text)
{
m_vector.insert(m_vector.begin()+pos, string_message::create(move(text)));
m_vector.insert(m_vector.begin()+pos, string_message::create(std::move(text)));
}

void insert(size_t pos,std::shared_ptr<std::string> const& binary)
Expand Down