From f7e8b05b7e51cb924ce5bd2a5c98650e83f03f99 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=AB=8F=E8=A8=AA=E5=AD=90?= Date: Mon, 15 Dec 2025 16:02:43 +0900 Subject: [PATCH] =?UTF-8?q?4=E3=83=93=E3=83=83=E3=83=88=E3=81=A8128?= =?UTF-8?q?=E3=83=93=E3=83=83=E3=83=88=E6=95=B0=E5=AD=97=E3=82=BF=E3=82=A4?= =?UTF-8?q?=E3=83=97=E3=81=AE=E8=BF=BD=E5=8A=A0=EF=BC=88C23=E3=81=AE?= =?UTF-8?q?=E3=81=BF=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- exstdtype.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/exstdtype.h b/exstdtype.h index 2495f80..d4a517d 100644 --- a/exstdtype.h +++ b/exstdtype.h @@ -69,4 +69,19 @@ typedef struct { i32 length; } String; +// 下記はC23のみの類だ +#if defined(__STDC_VERSION__) && __STDC_VERSION__ >= 202311L +typedef unsigned _BitInt(4) uint4_t; +typedef signed _BitInt(4) int4_t; +typedef unsigned _BitInt(4) u4; +typedef signed _BitInt(4) i4; + +#ifndef __SIZEOF_INT128__ +typedef unsigned _BitInt(128) uint128_t; +typedef signed _BitInt(128) int128_t; +typedef unsigned _BitInt(128) u128; +typedef signed _BitInt(128) i128; +#endif +#endif + #endif // __EXSTDTYPE_H