static int utf8len(const uint8_t *b)
{
    int len = 0;
    int val;
    while (*b) {
        GET_UTF8(val, *b++, return -1;)
        len++;
    }
    return len;
}
['static int utf8len(const uint8_t *b)\n{\n    int len = 0;\n    int val;\n    while (*b) {\n        GET_UTF8(val, *b++, return -1;)\n        len++;\n    }\n    return len;\n}']