diff options
author | Gregory Anders <8965202+gpanders@users.noreply.github.com> | 2023-08-15 09:25:51 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-15 09:25:51 -0500 |
commit | e72c0cd92090c1fc1e5665a060b3e1d0094d7f30 (patch) | |
tree | 78c1c4f21877e61091daa6df42381712b948ecd5 /src | |
parent | fc14928719df12826397b46b1765b82f1fc7d1d8 (diff) | |
download | rneovim-e72c0cd92090c1fc1e5665a060b3e1d0094d7f30.tar.gz rneovim-e72c0cd92090c1fc1e5665a060b3e1d0094d7f30.tar.bz2 rneovim-e72c0cd92090c1fc1e5665a060b3e1d0094d7f30.zip |
feat(highlight): Allow hyphens (-) in highlight group names (#24714)
Fixes: https://github.com/neovim/neovim/issues/23184
Diffstat (limited to 'src')
-rw-r--r-- | src/nvim/highlight_group.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/highlight_group.c b/src/nvim/highlight_group.c index de53545195..60cafb0abb 100644 --- a/src/nvim/highlight_group.c +++ b/src/nvim/highlight_group.c @@ -1942,7 +1942,7 @@ static int syn_add_group(const char *name, size_t len) if (!vim_isprintc(c)) { emsg(_("E669: Unprintable character in group name")); return 0; - } else if (!ASCII_ISALNUM(c) && c != '_' && c != '.' && c != '@') { + } else if (!ASCII_ISALNUM(c) && c != '_' && c != '.' && c != '@' && c != '-') { // '.' and '@' are allowed characters for use with treesitter capture names. msg_source(HL_ATTR(HLF_W)); emsg(_(e_highlight_group_name_invalid_char)); |