diff options
Diffstat (limited to 'src/nvim/mbyte_defs.h')
-rw-r--r-- | src/nvim/mbyte_defs.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/nvim/mbyte_defs.h b/src/nvim/mbyte_defs.h index efb4f558a6..97aa1a638b 100644 --- a/src/nvim/mbyte_defs.h +++ b/src/nvim/mbyte_defs.h @@ -1,6 +1,7 @@ #pragma once #include <stdbool.h> +#include <stdint.h> #include "nvim/iconv_defs.h" @@ -55,3 +56,13 @@ typedef struct { bool vc_fail; ///< What to do with invalid characters: if true, fail, ///< otherwise use '?'. } vimconv_T; + +typedef struct { + int32_t value; ///< code point + int len; ///< length in bytes +} CharInfo; + +typedef struct { + char *ptr; ///< pointer to the first byte of the character + CharInfo chr; ///< the character +} StrCharInfo; |