On 26 Feb 2019, at 16:33, i.koptelov <ivan.koptelov@tarantool.org> wrote:
On 25 Feb 2019, at 18:10, n.pettik <korablev@tarantool.org> wrote:

That’s I was talking about. But using the macros with the same
name as in utf library doesn’t look like a good pattern. Yep, you
can use define guards like:

#ifdef  U8_COUNT_TRAIL_BYTES_UNSAFE
#undef U8_COUNT_TRAIL_BYTES_UNSAFE
#endif
#define U8_COUNT_TRAIL_BYTES_UNSAFE

But I’d rather just give it another name.
Hence, taking into account comment below,
we are going to substitute SQL_SKIP_UTF8() with
implementation borrowed from icu library.
I changed the names to SQL_UTF8_FWD_1_UNSAFE and
SQL_UTF8_COUNT_TRAIL_BYTES_UNSAFE.

Won’t bother you with portion of minor comments.
I’ve pushed them, take a look. If they are OK, just
squash (but don’t squash last commit) them and
patch will be OK as well.

Also, I’ve fixed a bit commit message. Add please
doc request which includes user-visible changes.