Lines Matching refs:cbb
120 int cbb_add_utf8(CBB *cbb, uint32_t u) { in cbb_add_utf8() argument
125 return CBB_add_u8(cbb, (uint8_t)u); in cbb_add_utf8()
128 return CBB_add_u8(cbb, TOP_BITS(2) | (u >> 6)) && in cbb_add_utf8()
129 CBB_add_u8(cbb, TOP_BITS(1) | (u & BOTTOM_BITS(6))); in cbb_add_utf8()
132 return CBB_add_u8(cbb, TOP_BITS(3) | (u >> 12)) && in cbb_add_utf8()
133 CBB_add_u8(cbb, TOP_BITS(1) | ((u >> 6) & BOTTOM_BITS(6))) && in cbb_add_utf8()
134 CBB_add_u8(cbb, TOP_BITS(1) | (u & BOTTOM_BITS(6))); in cbb_add_utf8()
137 return CBB_add_u8(cbb, TOP_BITS(4) | (u >> 18)) && in cbb_add_utf8()
138 CBB_add_u8(cbb, TOP_BITS(1) | ((u >> 12) & BOTTOM_BITS(6))) && in cbb_add_utf8()
139 CBB_add_u8(cbb, TOP_BITS(1) | ((u >> 6) & BOTTOM_BITS(6))) && in cbb_add_utf8()
140 CBB_add_u8(cbb, TOP_BITS(1) | (u & BOTTOM_BITS(6))); in cbb_add_utf8()
145 int cbb_add_latin1(CBB *cbb, uint32_t u) { in cbb_add_latin1() argument
146 return u <= 0xff && CBB_add_u8(cbb, (uint8_t)u); in cbb_add_latin1()
149 int cbb_add_ucs2_be(CBB *cbb, uint32_t u) { in cbb_add_ucs2_be() argument
150 return u <= 0xffff && is_valid_code_point(u) && CBB_add_u16(cbb, (uint16_t)u); in cbb_add_ucs2_be()
153 int cbb_add_utf32_be(CBB *cbb, uint32_t u) { in cbb_add_utf32_be() argument
154 return is_valid_code_point(u) && CBB_add_u32(cbb, u); in cbb_add_utf32_be()