16 for(
size_t i = 0; val[ i ]; i++ )
19 if( ( c & 0b11000000 ) == 0b10000000 )
29 return ( c & 0b11000000 ) != 0b10000000;
32 void string_explode( std::string
const & s,
char delim, std::vector< std::string > & result )
34 std::istringstream iss(s);
35 for (std::string token; std::getline(iss, token, delim); )
36 result.push_back(std::move(token));
38 result.push_back(
"" );
48 if( c==
' ' || c==
'\n' || c==
'\r' || c==
'\t' )
57 return std::string(
"");
59 return s.substr( left, s.size()-right-left );
68 if( c==
' ' || c==
'\n' || c==
'\r' || c==
'\t' )
74 return std::string(
"");
76 return s.substr( left, s.size()-left );
84 if( c==
' ' || c==
'\n' || c==
'\r' || c==
'\t' )
89 if(
size_t(right) == s.size() )
90 return std::string(
"");
92 return s.substr( 0, s.size()-right );