Lines Matching defs:buffer
65 // If the 16 bits following the high surrogate are in the source buffer...
221 // Magic values subtracted from a buffer value during UTF8 conversion.
335 // Helper to write a three-byte UTF-8 code point to the buffer, caller must
337 static inline void putUTF8Triple(char*& buffer, UChar ch) {
338 *buffer++ = static_cast<char>(((ch >> 12) & 0x0F) | 0xE0);
339 *buffer++ = static_cast<char>(((ch >> 6) & 0x3F) | 0x80);
340 *buffer++ = static_cast<char>((ch & 0x3F) | 0x80);
347 // Allocate a buffer big enough to hold all the characters
351 // characters, and resize if necessary (i.e. if the buffer contains
352 // non-ascii characters). (Alternatively, scan the buffer first for
356 // buffer without reallocing (say, 1.5 x length).
362 char* buffer = &*output.begin();
367 &characters, characters_end, &buffer, buffer_end, /* strict= */ true);
377 DCHECK_LE(buffer + 3, buffer_end);
378 putUTF8Triple(buffer, replacementCharacter);
383 output.resize(buffer - output.data());
389 std::vector<uint16_t> buffer(length);
390 UChar* bufferStart = buffer.data();
396 &bufferCurrent, bufferCurrent + buffer.size(), nullptr,