MCPcopy Create free account
hub / github.com/KaisenAmin/c_std / encoding_initialize

Function encoding_initialize

encoding/encoding.c:2308–2312  ·  view source on GitHub ↗

* @brief Initializes the encoding library by setting the locale for character encoding. * * This function should be called at the beginning of the program to ensure proper handling of character encodings. */

Source from the content-addressed store, hash-verified

2306 utf8Str[o++] = (char)(0x80 | ((cp >> 6) & 0x3F));
2307 utf8Str[o++] = (char)(0x80 | (cp & 0x3F));
2308 }
2309 else {
2310 utf8Str[o++] = (char)(0xF0 | (cp >> 18));
2311 utf8Str[o++] = (char)(0x80 | ((cp >> 12) & 0x3F));
2312 utf8Str[o++] = (char)(0x80 | ((cp >> 6) & 0x3F));
2313 utf8Str[o++] = (char)(0x80 | (cp & 0x3F));
2314 }
2315 }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected