MCPcopy Create free account
hub / github.com/crawl/crawl / codepoints

Function codepoints

crawl-ref/source/stringutil.cc:113–120  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

111}
112
113int codepoints(string str)
114{
115 int len = 0;
116 for (char c : str)
117 if ((c & 0xc0) != 0x80)
118 ++len;
119 return len;
120}
121
122string padded_str(const string &s, int pad_to, bool prepend)
123{

Callers 2

PrintMethod · 0.85
padded_strFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected