/**
* Attempt to recompose two Unicode characters into a single character.
*
- * @param base: Base Unicode code point (UCS-4)
- * @param combining: Combining mark Unicode code point (UCS-4)
+ * @param previous: Previous Unicode code point (UCS-4)
+ * @param current: Current Unicode code point (UCS-4)
* Return: Recomposed Unicode code point, or 0 if no recomposition is possible
*/
uint32_t ucs_recompose(uint32_t base, uint32_t combining)
return 0;
struct compare_key key = {{ base, combining }};
+
struct recomposition *result =
__inline_bsearch(&key, recomposition_table,
ARRAY_SIZE(recomposition_table),
/**
* Determine if a Unicode code point is zero-width.
*
- * @param cp: Unicode code point (UCS-4)
+ * @param ucs: Unicode code point (UCS-4)
* Return: true if the character is zero-width, false otherwise
*/
bool ucs_is_zero_width(uint32_t cp)
/**
* Determine if a Unicode code point is double-width.
*
- * @param cp: Unicode code point (UCS-4)
+ * @param ucs: Unicode code point (UCS-4)
* Return: true if the character is double-width, false otherwise
*/
bool ucs_is_double_width(uint32_t cp)
/**
* Attempt to recompose two Unicode characters into a single character.
*
- * @param base: Base Unicode code point (UCS-4)
- * @param combining: Combining mark Unicode code point (UCS-4)
+ * @param previous: Previous Unicode code point (UCS-4)
+ * @param current: Current Unicode code point (UCS-4)
* Return: Recomposed Unicode code point, or 0 if no recomposition is possible
*/
uint32_t ucs_recompose(uint32_t base, uint32_t combining)
return 0;
struct compare_key key = { base, combining };
+
struct recomposition *result =
__inline_bsearch(&key, recomposition_table,
ARRAY_SIZE(recomposition_table),
/**
* Determine if a Unicode code point is zero-width.
*
- * @param cp: Unicode code point (UCS-4)
+ * @param ucs: Unicode code point (UCS-4)
* Return: true if the character is zero-width, false otherwise
*/
bool ucs_is_zero_width(uint32_t cp)
/**
* Determine if a Unicode code point is double-width.
*
- * @param cp: Unicode code point (UCS-4)
+ * @param ucs: Unicode code point (UCS-4)
* Return: true if the character is double-width, false otherwise
*/
bool ucs_is_double_width(uint32_t cp)