+/** \brief encodes UTF-8 sequence
+ \param x the UNICODE value
+ \param outbuf output buffer pointer, updated if conversion is successful
+ \param outbytesleft length of buffer, updated if conversino is successful
+ \param error pointer to error code if error occurs
+ \retval 0 if successful
+ \retval -1 for error
+*/
+YAZ_EXPORT size_t yaz_write_UTF8_char(unsigned long x,
+ char **outbuf, size_t *outbytesleft,
+ int *error);
+