Commit a2b24cb5 authored by Max Kellermann's avatar Max Kellermann

SongFilter: pass std::string&& to Item constructor

parent a54f9ede
......@@ -60,9 +60,9 @@ locate_parse_type(const char *str) noexcept
return tag_name_parse_i(str);
}
SongFilter::Item::Item(unsigned _tag, const char *_value, bool _fold_case)
SongFilter::Item::Item(unsigned _tag, std::string &&_value, bool _fold_case)
:tag(_tag),
value(_value),
value(std::move(_value)),
fold_case(_fold_case ? IcuCompare(value.c_str()) : IcuCompare())
{
}
......
......@@ -67,8 +67,7 @@ public:
std::chrono::system_clock::time_point time;
public:
gcc_nonnull(3)
Item(unsigned tag, const char *value, bool fold_case=false);
Item(unsigned tag, std::string &&_value, bool fold_case=false);
Item(unsigned tag, std::chrono::system_clock::time_point time);
unsigned GetTag() const {
......
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