diff options
author | ii14 <59243201+ii14@users.noreply.github.com> | 2023-04-07 19:40:57 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-07 19:40:57 +0200 |
commit | 9408f2dcf7cade2631688300e9b58eed6bc5219a (patch) | |
tree | 152b8b6135f50619b1fb2a69719d71a180ea0792 /src/nvim/spell.c | |
parent | 1d2a29f75ba7d094c8e7444c9b249a4a7211c93c (diff) | |
download | rneovim-9408f2dcf7cade2631688300e9b58eed6bc5219a.tar.gz rneovim-9408f2dcf7cade2631688300e9b58eed6bc5219a.tar.bz2 rneovim-9408f2dcf7cade2631688300e9b58eed6bc5219a.zip |
refactor: remove redundant const char * casts
Diffstat (limited to 'src/nvim/spell.c')
-rw-r--r-- | src/nvim/spell.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/spell.c b/src/nvim/spell.c index 6623ba47af..593e2f4d89 100644 --- a/src/nvim/spell.c +++ b/src/nvim/spell.c @@ -1316,7 +1316,7 @@ size_t spell_move_to(win_T *wp, int dir, bool allwords, bool curline, hlf_T *att // Copy the line into "buf" and append the start of the next line if // possible. Note: this ml_get_buf() may make "line" invalid, check // for empty line first. - bool empty_line = *skipwhite((const char *)line) == NUL; + bool empty_line = *skipwhite(line) == NUL; STRCPY(buf, line); if (lnum < wp->w_buffer->b_ml.ml_line_count) { spell_cat_line(buf + strlen(buf), @@ -1743,7 +1743,7 @@ void count_common_word(slang_T *lp, char *word, int len, uint8_t count) wordcount_T *wc; hash_T hash = hash_hash(p); const size_t p_len = strlen(p); - hashitem_T *hi = hash_lookup(&lp->sl_wordcount, (const char *)p, p_len, hash); + hashitem_T *hi = hash_lookup(&lp->sl_wordcount, p, p_len, hash); if (HASHITEM_EMPTY(hi)) { wc = xmalloc(offsetof(wordcount_T, wc_word) + p_len + 1); memcpy(wc->wc_word, p, p_len + 1); @@ -3129,9 +3129,9 @@ void ex_spellinfo(exarg_T *eap) for (int lpi = 0; lpi < curwin->w_s->b_langp.ga_len && !got_int; lpi++) { langp_T *const lp = LANGP_ENTRY(curwin->w_s->b_langp, lpi); msg_puts("file: "); - msg_puts((const char *)lp->lp_slang->sl_fname); + msg_puts(lp->lp_slang->sl_fname); msg_putchar('\n'); - const char *const p = (const char *)lp->lp_slang->sl_info; + const char *const p = lp->lp_slang->sl_info; if (p != NULL) { msg_puts(p); msg_putchar('\n'); |