MCPcopy Create free account
hub / github.com/chen3feng/toft / IsWhiteString

Function IsWhiteString

base/string/algorithm.h:18–29  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

16namespace toft {
17
18inline bool IsWhiteString(char const *str)
19{
20 if (!str) return false;
21
22 size_t i = 0;
23 size_t len = strlen(str);
24 while (isspace(str[i]) && i < len)
25 {
26 i++;
27 }
28 return (i == len);
29}
30
31inline bool IsCharInString(char c, const StringPiece& str)
32{

Callers 1

TESTFunction · 0.85

Calls

no outgoing calls

Tested by 1

TESTFunction · 0.68