parse: add specialisation for unsigned short

The code is horrific. Don't judge me.
This commit is contained in:
Danny Robson 2018-07-27 18:28:30 +10:00
parent 678e68a468
commit 3dc136595c

View File

@ -103,3 +103,11 @@ util::parse<unsigned> (util::view<const char*> str)
{
return util::cast::narrow<unsigned> (parse<unsigned long> (str));
}
template <>
unsigned short
util::parse<unsigned short> (util::view<const char*> str)
{
return util::cast::narrow<unsigned short> (parse<unsigned long> (str));
}