ref: 4b75c6aaf9a17788f78215072027f53b04d727e7
dir: /3rd/utf/utf.h/
#pragma once
enum {
Runeself = 0x80,
Runeerror = 0xfffd,
Runemax = 0x10ffff,
UTFmax = 4,
};
typedef uint32_t Rune;
int chartorune(Rune *rune, const char *str);
int runetochar(char *str, const Rune *rune);
int runenlen(const Rune *r, int nrune);
int fullrune(const char *str, int n);
int runelen(Rune c);
Rune tolowerrune(Rune c) fl_constfn;
Rune toupperrune(Rune c) fl_constfn;
Rune totitlerune(Rune c) fl_constfn;
int islowerrune(Rune c) fl_constfn;
int isupperrune(Rune c) fl_constfn;
int isalpharune(Rune c) fl_constfn;
int istitlerune(Rune c) fl_constfn;
int isspacerune(Rune c) fl_constfn;
int isdigitrune(Rune c) fl_constfn;
int utfnlen(const char *s, long m);