Fix signedness warnings in String.h
This commit is contained in:
parent
e2787e00e5
commit
f44d42dde8
@ -509,7 +509,7 @@ public:
|
||||
std::locale const &loc = std::locale::classic();
|
||||
String value(*this);
|
||||
for(value_type &ch : value)
|
||||
if(ch <= std::numeric_limits<ByteString::value_type>::max())
|
||||
if(ch <= static_cast<value_type>(std::numeric_limits<ByteString::value_type>::max()))
|
||||
ch = std::tolower(static_cast<ByteString::value_type>(ch), loc);
|
||||
return value;
|
||||
}
|
||||
@ -519,7 +519,7 @@ public:
|
||||
std::locale const &loc = std::locale::classic();
|
||||
String value(*this);
|
||||
for(value_type &ch : value)
|
||||
if(ch <= std::numeric_limits<ByteString::value_type>::max())
|
||||
if(ch <= static_cast<value_type>(std::numeric_limits<ByteString::value_type>::max()))
|
||||
ch = std::toupper(static_cast<ByteString::value_type>(ch), loc);
|
||||
return value;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user