aboutsummaryrefslogtreecommitdiff
path: root/lib/unicode/gbrk/u8glen.c
blob: 763a8346acaf4d092c9c625ccd184aad50de6953 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
#include "unicode/gbrk.h"

size_t
u8glen(const char8_t *s, size_t n)
{
	size_t m = 0;
	while (u8gnext(nullptr, &s, &n))
		m++;
	return m;
}