MCPcopy Create free account
hub / github.com/CppCXY/EmmyLuaCodeStyle / utf8codepointsize

Function utf8codepointsize

3rd/utf8/include/utf8.h:1209–1219  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1207}
1208
1209utf8_constexpr14_impl size_t utf8codepointsize(utf8_int32_t chr) {
1210 if (0 == ((utf8_int32_t)0xffffff80 & chr)) {
1211 return 1;
1212 } else if (0 == ((utf8_int32_t)0xfffff800 & chr)) {
1213 return 2;
1214 } else if (0 == ((utf8_int32_t)0xffff0000 & chr)) {
1215 return 3;
1216 } else { // if (0 == ((int)0xffe00000 & chr)) {
1217 return 4;
1218 }
1219}
1220
1221utf8_int8_t *utf8catcodepoint(utf8_int8_t *str, utf8_int32_t chr, size_t n) {
1222 if (0 == ((utf8_int32_t)0xffffff80 & chr)) {

Callers 2

utf8ncasecmpFunction · 0.85
utf8.hFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected