VOID CharsUtilTest() { CHAR c = 'a'; TEST('A' == CharToUpper(c), "CharToUpper failed"); TEST(10 == CharToHexDigit(c), "CharToHexDigit failed"); TEST(false == CharIsSpace(c), "CharIsSpace failed"); TEST(true == CharIsSpace(' '), "CharIsSpace failed"); //printf("Chars util tests completed\n"); }
ulen Tokenizer::ScanSpace(StrLen text) { ulen len=text.len; for(; +text && CharIsSpace(*text) ;++text); return len-text.len; }
template <class T> T _NextWhiteSpaceOrQuote(T psz) { while ((0 != psz[0]) && ! ('"' == psz[0]) && ! CharIsSpace(psz[0])) { psz = CharNext(psz); } return psz; }
template <class T> T _SkipWhiteSpace(T psz) { while(CharIsSpace(psz[0])) { psz = CharNext(psz); } return psz; }