Lines Matching defs:codepoint
9799 uint32_t codepoint = p->digit;
9801 /* emit the codepoint as UTF-8. */
9804 if (codepoint <= 0x7F) {
9805 utf8[0] = codepoint;
9807 } else if (codepoint <= 0x07FF) {
9808 utf8[1] = (codepoint & 0x3F) | 0x80;
9809 codepoint >>= 6;
9810 utf8[0] = (codepoint & 0x1F) | 0xC0;
9812 } else /* codepoint <= 0xFFFF */ {
9813 utf8[2] = (codepoint & 0x3F) | 0x80;
9814 codepoint >>= 6;
9815 utf8[1] = (codepoint & 0x3F) | 0x80;
9816 codepoint >>= 6;
9817 utf8[0] = (codepoint & 0x0F) | 0xE0;
9820 /* TODO(haberman): Handle high surrogates: if codepoint is a high surrogate