1 2 3 4 5 6 7 8 9
#include "rune.h" #include "utf8.h" bool u8chkr(rune ch) { return !((ch >= 0xD800 && ch <= 0xDFFF) || ch == 0xFFFE || ch == 0xFFFF || ch > RUNE_MAX); }