diff options
author | bfredl <bjorn.linse@gmail.com> | 2022-11-08 09:48:48 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-08 09:48:48 +0100 |
commit | fae754073289566051433fae74ec65783f9e7a6a (patch) | |
tree | 27fa3555e5a8a016dce55cc39f20599e32cf7046 /src/nvim/syntax.c | |
parent | d187c00faf4feb76bdc544b87bea71f217d05957 (diff) | |
parent | 731cdde28ea8d48cc23ba2752a08c261c87eee92 (diff) | |
download | rneovim-fae754073289566051433fae74ec65783f9e7a6a.tar.gz rneovim-fae754073289566051433fae74ec65783f9e7a6a.tar.bz2 rneovim-fae754073289566051433fae74ec65783f9e7a6a.zip |
Merge pull request #20821 from dundargoc/refactor/clang-tidy
refactor: fix clang-tidy warnings
Diffstat (limited to 'src/nvim/syntax.c')
-rw-r--r-- | src/nvim/syntax.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/src/nvim/syntax.c b/src/nvim/syntax.c index 7248d1240e..fe1bdf12b1 100644 --- a/src/nvim/syntax.c +++ b/src/nvim/syntax.c @@ -3122,22 +3122,20 @@ static void syn_cmd_clear(exarg_T *eap, int syncing) if (id == 0) { semsg(_("E391: No such syntax cluster: %s"), arg); break; - } else { - // We can't physically delete a cluster without changing - // the IDs of other clusters, so we do the next best thing - // and make it empty. - int scl_id = id - SYNID_CLUSTER; - - XFREE_CLEAR(SYN_CLSTR(curwin->w_s)[scl_id].scl_list); } + // We can't physically delete a cluster without changing + // the IDs of other clusters, so we do the next best thing + // and make it empty. + int scl_id = id - SYNID_CLUSTER; + + XFREE_CLEAR(SYN_CLSTR(curwin->w_s)[scl_id].scl_list); } else { id = syn_name2id_len(arg, (size_t)(arg_end - arg)); if (id == 0) { semsg(_(e_nogroup), arg); break; - } else { - syn_clear_one(id, syncing); } + syn_clear_one(id, syncing); } arg = skipwhite(arg_end); } |