diff options
author | Thomas Voss <mail@thomasvoss.com> | 2024-03-10 17:25:09 +0200 |
---|---|---|
committer | Thomas Voss <mail@thomasvoss.com> | 2024-03-10 17:25:09 +0200 |
commit | c3d40a0dba2d4cff85ef78d06973aeacc778cc74 (patch) | |
tree | f94238037c1550d8d53df7092a8883ed780d0c99 /include/mbstring.h | |
parent | 8abb53d6786b822ba777dd5ada337e6772da309f (diff) |
Make optparse() use u8view’s for longopts
Diffstat (limited to 'include/mbstring.h')
-rw-r--r-- | include/mbstring.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/mbstring.h b/include/mbstring.h index 3ac9277..9a95836 100644 --- a/include/mbstring.h +++ b/include/mbstring.h @@ -8,6 +8,8 @@ #include "__rune.h" #include "__u8view.h" +#define U8V(s) ((struct u8view){.p = (s), .len = sizeof(s) - 1}) + /* clang-format off */ #define U8_BYTE_1(x) (((x) & 0x80) == 0x00) #define U8_BYTE_2(x) (((x) & 0xE0) == 0xC0) |