parse/value: remove pessimising move

This commit is contained in:
Danny Robson 2019-05-04 11:33:21 +10:00
parent 1d387ea323
commit a03bdf5e1d

View File

@ -33,7 +33,7 @@ namespace cruft::parse {
T res = value<T> (data);
if (!data.empty ())
throw std::invalid_argument ("unable to parse");
return std::move (res);
return res;
}
template <typename T> T from_string (const char *data) { return from_string<T> (cruft::view (data)); }