pass by value instead of rvalue reference for RVO to take place

This commit is contained in:
Andrzej Rybczak
2014-11-01 01:37:32 +01:00
parent 7e2900511c
commit e9a539f8ee
3 changed files with 25 additions and 25 deletions

View File

@@ -199,7 +199,7 @@ bool Statusbar::Helpers::mainHook(const char *)
return true;
}
std::string Statusbar::Helpers::promptReturnOneOf(std::vector<std::string> &&values)
std::string Statusbar::Helpers::promptReturnOneOf(std::vector<std::string> values)
{
Statusbar::Helpers::ImmediatelyReturnOneOf prompt_hook(std::move(values));
NC::Window::ScopedPromptHook hook(*wFooter, prompt_hook);