Lines Matching refs:data
319 static utf8leaf_t *utf8nlookup(const struct utf8data *data, in utf8nlookup() argument
328 if (!data) in utf8nlookup()
333 trie = utf8data + data->offset; in utf8nlookup()
395 static utf8leaf_t *utf8lookup(const struct utf8data *data, in utf8lookup() argument
398 return utf8nlookup(data, hangul, s, (size_t)-1); in utf8lookup()
406 int utf8agemax(const struct utf8data *data, const char *s) in utf8agemax() argument
413 if (!data) in utf8agemax()
417 leaf = utf8lookup(data, hangul, s); in utf8agemax()
422 if (leaf_age <= data->maxage && leaf_age > age) in utf8agemax()
435 int utf8agemin(const struct utf8data *data, const char *s) in utf8agemin() argument
442 if (!data) in utf8agemin()
444 age = data->maxage; in utf8agemin()
446 leaf = utf8lookup(data, hangul, s); in utf8agemin()
450 if (leaf_age <= data->maxage && leaf_age < age) in utf8agemin()
462 int utf8nagemax(const struct utf8data *data, const char *s, size_t len) in utf8nagemax() argument
469 if (!data) in utf8nagemax()
473 leaf = utf8nlookup(data, hangul, s, len); in utf8nagemax()
477 if (leaf_age <= data->maxage && leaf_age > age) in utf8nagemax()
490 int utf8nagemin(const struct utf8data *data, const char *s, size_t len) in utf8nagemin() argument
497 if (!data) in utf8nagemin()
499 age = data->maxage; in utf8nagemin()
501 leaf = utf8nlookup(data, hangul, s, len); in utf8nagemin()
505 if (leaf_age <= data->maxage && leaf_age < age) in utf8nagemin()
520 ssize_t utf8len(const struct utf8data *data, const char *s) in utf8len() argument
526 if (!data) in utf8len()
529 leaf = utf8lookup(data, hangul, s); in utf8len()
532 if (utf8agetab[LEAF_GEN(leaf)] > data->maxage) in utf8len()
548 ssize_t utf8nlen(const struct utf8data *data, const char *s, size_t len) in utf8nlen() argument
554 if (!data) in utf8nlen()
557 leaf = utf8nlookup(data, hangul, s, len); in utf8nlen()
560 if (utf8agetab[LEAF_GEN(leaf)] > data->maxage) in utf8nlen()
583 int utf8ncursor(struct utf8cursor *u8c, const struct utf8data *data, in utf8ncursor() argument
586 if (!data) in utf8ncursor()
590 u8c->data = data; in utf8ncursor()
618 int utf8cursor(struct utf8cursor *u8c, const struct utf8data *data, in utf8cursor() argument
621 return utf8ncursor(u8c, data, s, (unsigned int)-1); in utf8cursor()
681 leaf = utf8lookup(u8c->data, u8c->hangul, u8c->s); in utf8byte()
683 leaf = utf8nlookup(u8c->data, u8c->hangul, in utf8byte()
693 if (utf8agetab[LEAF_GEN(leaf)] > u8c->data->maxage) { in utf8byte()
707 leaf = utf8lookup(u8c->data, u8c->hangul, u8c->s); in utf8byte()