aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/highlight.c
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2021-10-12 17:52:54 +0200
committerGitHub <noreply@github.com>2021-10-12 17:52:54 +0200
commit649b3160a10f0053747383f0703b0a5a94548570 (patch)
tree2898b7213ab1349717c360c8d7561a4606f3c8c2 /src/nvim/highlight.c
parent64f0fdc6822db4fc1ef5fadb892aab5bf04e75a7 (diff)
downloadrneovim-649b3160a10f0053747383f0703b0a5a94548570.tar.gz
rneovim-649b3160a10f0053747383f0703b0a5a94548570.tar.bz2
rneovim-649b3160a10f0053747383f0703b0a5a94548570.zip
refactor: reduce number of unique char casts (#15995)
Diffstat (limited to 'src/nvim/highlight.c')
-rw-r--r--src/nvim/highlight.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/highlight.c b/src/nvim/highlight.c
index bb325b3f25..737e668e81 100644
--- a/src/nvim/highlight.c
+++ b/src/nvim/highlight.c
@@ -306,7 +306,7 @@ void update_window_hl(win_T *wp, bool invalid)
// syntax group! It needs at least 10 layers of special casing! Noooooo!
//
// haha, theme engine go brrr
- int normality = syn_check_group((const char_u *)S_LEN("Normal"));
+ int normality = syn_check_group(S_LEN("Normal"));
int ns_attr = ns_get_hl(-1, normality, false, false);
if (ns_attr > 0) {
// TODO(bfredl): hantera NormalNC and so on
@@ -890,7 +890,7 @@ HlAttrs dict2hlattrs(Dictionary dict, bool use_rgb, int *link_id, Error *err)
} else if (link_id && strequal(key, "link")) {
if (val.type == kObjectTypeString) {
String str = val.data.string;
- *link_id = syn_check_group((const char_u *)str.data, (int)str.size);
+ *link_id = syn_check_group(str.data, (int)str.size);
} else if (val.type == kObjectTypeInteger) {
// TODO(bfredl): validate range?
*link_id = (int)val.data.integer;