mirror of
https://github.com/pocoproject/poco.git
synced 2025-12-10 18:14:58 +01:00
enh(Foundation): modernised header files (override, using, nullptr, ...)
This commit is contained in:
@@ -44,8 +44,8 @@ std::size_t cstrlen(const C* str)
|
||||
/// provided that call strlen() and wcslen().
|
||||
{
|
||||
const C* end = str;
|
||||
while (*end) ++end;
|
||||
return end - str;
|
||||
while (*end) ++end;
|
||||
return end - str;
|
||||
}
|
||||
|
||||
|
||||
@@ -288,13 +288,13 @@ int icompare(const S& str1, const S& str2)
|
||||
// A special optimization for an often used case.
|
||||
{
|
||||
typename S::const_iterator it1(str1.begin());
|
||||
typename S::const_iterator end1(str1.end());
|
||||
const typename S::const_iterator end1(str1.end());
|
||||
typename S::const_iterator it2(str2.begin());
|
||||
typename S::const_iterator end2(str2.end());
|
||||
const typename S::const_iterator end2(str2.end());
|
||||
while (it1 != end1 && it2 != end2)
|
||||
{
|
||||
typename S::value_type c1(static_cast<typename S::value_type>(Ascii::toLower(*it1)));
|
||||
typename S::value_type c2(static_cast<typename S::value_type>(Ascii::toLower(*it2)));
|
||||
const typename S::value_type c1(static_cast<typename S::value_type>(Ascii::toLower(*it1)));
|
||||
const typename S::value_type c2(static_cast<typename S::value_type>(Ascii::toLower(*it2)));
|
||||
if (c1 < c2)
|
||||
return -1;
|
||||
else if (c1 > c2)
|
||||
@@ -773,7 +773,7 @@ struct i_char_traits : public std::char_traits<charT>
|
||||
};
|
||||
|
||||
|
||||
typedef std::basic_string<char, i_char_traits<char>> istring;
|
||||
using istring = std::basic_string<char, i_char_traits<char>>;
|
||||
/// Case-insensitive std::string counterpart.
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user