/external/libchrome/base/strings/ |
D | utf_string_conversion_utils.h | 18 inline bool IsValidCodepoint(uint32_t code_point) { in IsValidCodepoint() argument 22 return code_point < 0xD800u || in IsValidCodepoint() 23 (code_point >= 0xE000u && code_point <= 0x10FFFFu); in IsValidCodepoint() 26 inline bool IsValidCharacter(uint32_t code_point) { in IsValidCharacter() argument 29 return code_point < 0xD800u || (code_point >= 0xE000u && in IsValidCharacter() 30 code_point < 0xFDD0u) || (code_point > 0xFDEFu && in IsValidCharacter() 31 code_point <= 0x10FFFFu && (code_point & 0xFFFEu) != 0xFFFEu); in IsValidCharacter() 52 uint32_t* code_point); 59 uint32_t* code_point); 66 BASE_EXPORT size_t WriteUnicodeCharacter(uint32_t code_point, [all …]
|
D | utf_string_conversion_utils.cc | 20 int32_t code_point; in ReadUnicodeCharacter() local 21 CBU8_NEXT(src, *char_index, src_len, code_point); in ReadUnicodeCharacter() 22 *code_point_out = static_cast<uint32_t>(code_point); in ReadUnicodeCharacter() 29 return IsValidCodepoint(code_point); in ReadUnicodeCharacter() 35 uint32_t* code_point) { in ReadUnicodeCharacter() argument 45 *code_point = CBU16_GET_SUPPLEMENTARY(src[*char_index], in ReadUnicodeCharacter() 50 *code_point = src[*char_index]; in ReadUnicodeCharacter() 53 return IsValidCodepoint(*code_point); in ReadUnicodeCharacter() 60 uint32_t* code_point) { in ReadUnicodeCharacter() argument 62 *code_point = src[*char_index]; in ReadUnicodeCharacter() [all …]
|
D | utf_string_conversions.cc | 32 uint32_t code_point; in ConvertUnicode() local 33 if (ReadUnicodeCharacter(src, src_len32, &i, &code_point)) { in ConvertUnicode() 34 WriteUnicodeCharacter(code_point, output); in ConvertUnicode()
|
D | string_util.cc | 372 base_icu::UChar32 code_point = 0; in TruncateUTF8ToByteSize() local 373 CBU8_NEXT(data, char_index, truncation_length, code_point); in TruncateUTF8ToByteSize() 374 if (!IsValidCharacter(code_point) || in TruncateUTF8ToByteSize() 375 !IsValidCodepoint(code_point)) { in TruncateUTF8ToByteSize() 525 int32_t code_point; in IsStringUTF8() local 526 CBU8_NEXT(src, char_index, src_len, code_point); in IsStringUTF8() 527 if (!IsValidCharacter(code_point)) in IsStringUTF8()
|
/external/libweave/third_party/chromium/base/strings/ |
D | utf_string_conversion_utils.h | 19 inline bool IsValidCodepoint(uint32_t code_point) { in IsValidCodepoint() argument 23 return code_point < 0xD800u || in IsValidCodepoint() 24 (code_point >= 0xE000u && code_point <= 0x10FFFFu); in IsValidCodepoint() 27 inline bool IsValidCharacter(uint32_t code_point) { in IsValidCharacter() argument 30 return code_point < 0xD800u || (code_point >= 0xE000u && in IsValidCharacter() 31 code_point < 0xFDD0u) || (code_point > 0xFDEFu && in IsValidCharacter() 32 code_point <= 0x10FFFFu && (code_point & 0xFFFEu) != 0xFFFEu); in IsValidCharacter() 54 uint32_t* code_point); 62 size_t WriteUnicodeCharacter(uint32_t code_point, std::string* output); 67 inline size_t WriteUnicodeCharacter(uint32_t code_point, std::wstring* output) { in WriteUnicodeCharacter() argument [all …]
|
D | utf_string_conversion_utils.cc | 20 int32_t code_point; in ReadUnicodeCharacter() local 21 CBU8_NEXT(src, *char_index, src_len, code_point); in ReadUnicodeCharacter() 22 *code_point_out = static_cast<uint32_t>(code_point); in ReadUnicodeCharacter() 29 return IsValidCodepoint(code_point); in ReadUnicodeCharacter() 34 size_t WriteUnicodeCharacter(uint32_t code_point, std::string* output) { in WriteUnicodeCharacter() argument 35 if (code_point <= 0x7f) { in WriteUnicodeCharacter() 37 output->push_back(static_cast<char>(code_point)); in WriteUnicodeCharacter() 47 CBU8_APPEND_UNSAFE(&(*output)[0], char_offset, code_point); in WriteUnicodeCharacter()
|
D | string_util.cc | 237 int32_t code_point; in IsStringUTF8() local 238 CBU8_NEXT(src, char_index, src_len, code_point); in IsStringUTF8() 239 if (!IsValidCharacter(code_point)) in IsStringUTF8()
|
/external/libweave/third_party/chromium/base/json/ |
D | string_escape.cc | 35 bool EscapeSpecialCodePoint(uint32_t code_point, std::string* dest) { in EscapeSpecialCodePoint() argument 39 switch (code_point) { in EscapeSpecialCodePoint() 93 uint32_t code_point; in EscapeJSONStringImpl() local 94 if (!ReadUnicodeCharacter(str.data(), length, &i, &code_point)) { in EscapeJSONStringImpl() 95 code_point = kReplacementCodePoint; in EscapeJSONStringImpl() 99 if (EscapeSpecialCodePoint(code_point, dest)) in EscapeJSONStringImpl() 103 if (code_point < 32) in EscapeJSONStringImpl() 104 base::StringAppendF(dest, kU16EscapeFormat, code_point); in EscapeJSONStringImpl() 106 WriteUnicodeCharacter(code_point, dest); in EscapeJSONStringImpl()
|
D | json_parser.cc | 781 uint32_t code_point = in DecodeUTF16() local 783 if (!IsValidCharacter(code_point)) in DecodeUTF16() 787 CBU8_APPEND_UNSAFE(code_unit8, offset, code_point); in DecodeUTF16()
|
/external/libchrome/base/json/ |
D | string_escape.cc | 35 bool EscapeSpecialCodePoint(uint32_t code_point, std::string* dest) { in EscapeSpecialCodePoint() argument 39 switch (code_point) { in EscapeSpecialCodePoint() 93 uint32_t code_point; in EscapeJSONStringImpl() local 94 if (!ReadUnicodeCharacter(str.data(), length, &i, &code_point)) { in EscapeJSONStringImpl() 95 code_point = kReplacementCodePoint; in EscapeJSONStringImpl() 99 if (EscapeSpecialCodePoint(code_point, dest)) in EscapeJSONStringImpl() 103 if (code_point < 32) in EscapeJSONStringImpl() 104 base::StringAppendF(dest, kU16EscapeFormat, code_point); in EscapeJSONStringImpl() 106 WriteUnicodeCharacter(code_point, dest); in EscapeJSONStringImpl()
|
D | json_parser.cc | 786 uint32_t code_point = in DecodeUTF16() local 788 if (!IsValidCharacter(code_point)) in DecodeUTF16() 792 CBU8_APPEND_UNSAFE(code_unit8, offset, code_point); in DecodeUTF16()
|
/external/protobuf/src/google/protobuf/io/ |
D | tokenizer.cc | 915 static void AppendUTF8(uint32 code_point, string* output) { in AppendUTF8() argument 918 if (code_point <= 0x7f) { in AppendUTF8() 919 tmp = code_point; in AppendUTF8() 921 } else if (code_point <= 0x07ff) { in AppendUTF8() 923 ((code_point & 0x07c0) << 2) | in AppendUTF8() 924 (code_point & 0x003f); in AppendUTF8() 926 } else if (code_point <= 0xffff) { in AppendUTF8() 928 ((code_point & 0xf000) << 4) | in AppendUTF8() 929 ((code_point & 0x0fc0) << 2) | in AppendUTF8() 930 (code_point & 0x003f); in AppendUTF8() [all …]
|
/external/vboot_reference/cgpt/ |
D | cgpt_common.c | 443 uint32_t code_point = 0; in UTF16ToUTF8() local 461 code_point = (codeunit & 0x03FF) + 0x0040; in UTF16ToUTF8() 464 code_point = codeunit; in UTF16ToUTF8() 469 code_point = (code_point << 10) | (codeunit & 0x03FF); in UTF16ToUTF8() 481 require(code_point <= 0x10FFFF); in UTF16ToUTF8() 482 if (code_point <= 0x7F && maxoutput >= 1) { in UTF16ToUTF8() 484 utf8[s8idx++] = code_point & 0x7F; in UTF16ToUTF8() 485 } else if (code_point <= 0x7FF && maxoutput >= 2) { in UTF16ToUTF8() 487 utf8[s8idx++] = 0xC0 | (code_point >> 6); in UTF16ToUTF8() 488 utf8[s8idx++] = 0x80 | (code_point & 0x3F); in UTF16ToUTF8() [all …]
|
/external/v8/src/ |
D | unicode-inl.h | 14 template <class T, int s> bool Predicate<T, s>::get(uchar code_point) { in get() argument 15 CacheEntry entry = entries_[code_point & kMask]; in get() 16 if (entry.code_point() == code_point) return entry.value(); in get() 17 return CalculateValue(code_point); in get() 21 uchar code_point) { in CalculateValue() argument 22 bool result = T::Is(code_point); in CalculateValue() 23 entries_[code_point & kMask] = CacheEntry(code_point, result); in CalculateValue()
|
D | unicode.h | 40 inline CacheEntry(uchar code_point, bool value) in CacheEntry() argument 41 : bit_field_(CodePointField::encode(code_point) | in CacheEntry() 44 uchar code_point() const { return CodePointField::decode(bit_field_); } in code_point() function 73 inline CacheEntry(uchar code_point, signed offset) in CacheEntry() 74 : code_point_(code_point), in CacheEntry()
|
/external/antlr/antlr-3.4/tool/src/main/java/org/antlr/codegen/ |
D | RubyTarget.java | 372 int code_point = 0; in getTargetCharLiteralFromANTLRCharLiteral() local 380 code_point = literal.codePointAt( 1 ); in getTargetCharLiteralFromANTLRCharLiteral() 383 code_point = 10; in getTargetCharLiteralFromANTLRCharLiteral() 386 code_point = 13; in getTargetCharLiteralFromANTLRCharLiteral() 389 code_point = 9; in getTargetCharLiteralFromANTLRCharLiteral() 392 code_point = 8; in getTargetCharLiteralFromANTLRCharLiteral() 395 code_point = 12; in getTargetCharLiteralFromANTLRCharLiteral() 398 code_point = Integer.parseInt( literal.substring( 2 ), 16 ); in getTargetCharLiteralFromANTLRCharLiteral() 405 code_point = literal.codePointAt( 0 ); in getTargetCharLiteralFromANTLRCharLiteral() 410 return ( "0x" + Integer.toHexString( code_point ) ); in getTargetCharLiteralFromANTLRCharLiteral()
|
/external/unicode/ |
D | emoji-zwj-sequences.txt | 13 # code_point(s) ; type_field # version [count] name(s) 14 # code_point(s): one or more code points in hex format, separated by spaces
|
/external/llvm/utils/unittest/googletest/src/ |
D | gtest.cc | 1435 char* CodePointToUtf8(UInt32 code_point, char* str) { in CodePointToUtf8() argument 1436 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 1438 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 1439 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 1441 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1442 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 1443 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 1445 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1446 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1447 str[0] = static_cast<char>(0xE0 | code_point); // 1110xxxx in CodePointToUtf8() [all …]
|
/external/google-breakpad/src/testing/gtest/src/ |
D | gtest.cc | 1436 char* CodePointToUtf8(UInt32 code_point, char* str) { in CodePointToUtf8() argument 1437 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 1439 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 1440 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 1442 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1443 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 1444 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 1446 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1447 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1448 str[0] = static_cast<char>(0xE0 | code_point); // 1110xxxx in CodePointToUtf8() [all …]
|
/external/mesa3d/src/gtest/src/ |
D | gtest.cc | 1435 char* CodePointToUtf8(UInt32 code_point, char* str) { in CodePointToUtf8() argument 1436 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 1438 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 1439 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 1441 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1442 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 1443 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 1445 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1446 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1447 str[0] = static_cast<char>(0xE0 | code_point); // 1110xxxx in CodePointToUtf8() [all …]
|
/external/protobuf/gtest/src/ |
D | gtest.cc | 1456 char* CodePointToUtf8(UInt32 code_point, char* str) { in CodePointToUtf8() argument 1457 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 1459 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 1460 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 1462 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1463 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 1464 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 1466 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1467 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1468 str[0] = static_cast<char>(0xE0 | code_point); // 1110xxxx in CodePointToUtf8() [all …]
|
/external/vulkan-validation-layers/tests/gtest-1.7.0/src/ |
D | gtest.cc | 1436 std::string CodePointToUtf8(UInt32 code_point) { in CodePointToUtf8() argument 1437 if (code_point > kMaxCodePoint4) { in CodePointToUtf8() 1438 return "(Invalid Unicode 0x" + String::FormatHexInt(code_point) + ")"; in CodePointToUtf8() 1442 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 1444 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 1445 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 1447 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1448 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 1449 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 1451 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() [all …]
|
/external/gtest/src/ |
D | gtest.cc | 1436 std::string CodePointToUtf8(UInt32 code_point) { in CodePointToUtf8() argument 1437 if (code_point > kMaxCodePoint4) { in CodePointToUtf8() 1438 return "(Invalid Unicode 0x" + String::FormatHexInt(code_point) + ")"; in CodePointToUtf8() 1442 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 1444 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 1445 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 1447 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 1448 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 1449 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 1451 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() [all …]
|
/external/protobuf/gtest/fused-src/gtest/ |
D | gtest-all.cc | 613 GTEST_API_ char* CodePointToUtf8(UInt32 code_point, char* str); 2796 char* CodePointToUtf8(UInt32 code_point, char* str) { in CodePointToUtf8() argument 2797 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 2799 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 2800 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 2802 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 2803 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 2804 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() 2806 str[2] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 2807 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() [all …]
|
/external/libvpx/libvpx/third_party/googletest/src/src/ |
D | gtest-all.cc | 633 GTEST_API_ std::string CodePointToUtf8(UInt32 code_point); 2920 std::string CodePointToUtf8(UInt32 code_point) { in CodePointToUtf8() argument 2921 if (code_point > kMaxCodePoint4) { in CodePointToUtf8() 2922 return "(Invalid Unicode 0x" + String::FormatHexInt(code_point) + ")"; in CodePointToUtf8() 2926 if (code_point <= kMaxCodePoint1) { in CodePointToUtf8() 2928 str[0] = static_cast<char>(code_point); // 0xxxxxxx in CodePointToUtf8() 2929 } else if (code_point <= kMaxCodePoint2) { in CodePointToUtf8() 2931 str[1] = static_cast<char>(0x80 | ChopLowBits(&code_point, 6)); // 10xxxxxx in CodePointToUtf8() 2932 str[0] = static_cast<char>(0xC0 | code_point); // 110xxxxx in CodePointToUtf8() 2933 } else if (code_point <= kMaxCodePoint3) { in CodePointToUtf8() [all …]
|