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

size_t
u8gcnt(struct u8view sv)
{
	size_t m = 0;
	while (u8gnext(nullptr, &sv))
		m++;
	return m;
}