Lines Matching defs:code
8 // * Redistributions of source code must retain the above copyright
105 // his code.
984 // just to avoid copy-and-paste of similar code.
1207 // Looks up the human-readable system message for the HRESULT code
1258 // A Unicode code-point can have upto 21 bits, and is encoded in UTF-8
1261 // Code-point length Encoding
1267 // The maximum code-point a one-byte UTF-8 sequence can represent.
1270 // The maximum code-point a two-byte UTF-8 sequence can represent.
1273 // The maximum code-point a three-byte UTF-8 sequence can represent.
1276 // The maximum code-point a four-byte UTF-8 sequence can represent.
1288 // Converts a Unicode code-point to its UTF-8 encoding.
1292 UInt32 code = static_cast<UInt32>(wchar);
1293 if (code <= kMaxCodePoint1) {
1294 str[0] = static_cast<char>(code); // 0xxxxxxx
1295 } else if (code <= kMaxCodePoint2) {
1296 str[1] = static_cast<char>(0x80 | ChopLowBits(&code, 6)); // 10xxxxxx
1297 str[0] = static_cast<char>(0xC0 | code); // 110xxxxx
1298 } else if (code <= kMaxCodePoint3) {
1299 str[2] = static_cast<char>(0x80 | ChopLowBits(&code, 6)); // 10xxxxxx
1300 str[1] = static_cast<char>(0x80 | ChopLowBits(&code, 6)); // 10xxxxxx
1301 str[0] = static_cast<char>(0xE0 | code); // 1110xxxx
1302 } else if (code <= kMaxCodePoint4) {
1303 str[3] = static_cast<char>(0x80 | ChopLowBits(&code, 6)); // 10xxxxxx
1304 str[2] = static_cast<char>(0x80 | ChopLowBits(&code, 6)); // 10xxxxxx
1305 str[1] = static_cast<char>(0x80 | ChopLowBits(&code, 6)); // 10xxxxxx
1306 str[0] = static_cast<char>(0xF0 | code); // 11110xxx
1706 message << "Exception thrown with code 0x" << std::setbase(16) <<
2196 // Returns the ANSI color code for the given color.
2859 // UnitTest object upon exiting the program messes up the exit code,
2895 // this to report their results. The user code should use the
2967 printf("Exception thrown with code 0x%x.\nFAIL\n", GetExceptionCode());