mirror of
https://github.com/pocoproject/poco.git
synced 2025-11-26 09:07:49 +01:00
trunk/branch integration: using Poco::Ascii
This commit is contained in:
@@ -35,7 +35,7 @@
|
|||||||
|
|
||||||
|
|
||||||
#include "Poco/StringTokenizer.h"
|
#include "Poco/StringTokenizer.h"
|
||||||
#include <cctype>
|
#include "Poco/Ascii.h"
|
||||||
|
|
||||||
|
|
||||||
namespace Poco {
|
namespace Poco {
|
||||||
@@ -52,7 +52,7 @@ StringTokenizer::StringTokenizer(const std::string& str, const std::string& sepa
|
|||||||
{
|
{
|
||||||
if (options & TOK_TRIM)
|
if (options & TOK_TRIM)
|
||||||
{
|
{
|
||||||
while (it1 != end && std::isspace(*it1)) ++it1;
|
while (it1 != end && Ascii::isSpace(*it1)) ++it1;
|
||||||
}
|
}
|
||||||
it2 = it1;
|
it2 = it1;
|
||||||
while (it2 != end && separators.find(*it2) == std::string::npos) ++it2;
|
while (it2 != end && separators.find(*it2) == std::string::npos) ++it2;
|
||||||
@@ -60,8 +60,8 @@ StringTokenizer::StringTokenizer(const std::string& str, const std::string& sepa
|
|||||||
if (it3 != it1 && (options & TOK_TRIM))
|
if (it3 != it1 && (options & TOK_TRIM))
|
||||||
{
|
{
|
||||||
--it3;
|
--it3;
|
||||||
while (it3 != it1 && std::isspace(*it3)) --it3;
|
while (it3 != it1 && Ascii::isSpace(*it3)) --it3;
|
||||||
if (!std::isspace(*it3)) ++it3;
|
if (!Ascii::isSpace(*it3)) ++it3;
|
||||||
}
|
}
|
||||||
if (options & TOK_IGNORE_EMPTY)
|
if (options & TOK_IGNORE_EMPTY)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user