12 lines
332 B
C
12 lines
332 B
C
/* This software is licensed by the MIT License, see LICENSE file */
|
|
/* Copyright © 2022 Gregory Lirent */
|
|
|
|
#include "build.h"
|
|
|
|
int char32size(const char32_t* s) {
|
|
if (*(unsigned int*)s <= 0x10ffff && (*(unsigned int*)s < 0xd800 || *(unsigned int*)s > 0xdfff))
|
|
return 1;
|
|
|
|
return 0;
|
|
}
|