Skip to content

Commit

Permalink
patch 9.0.1711: dead code in charset.c
Browse files Browse the repository at this point in the history
Problem: dead code in charset.c
Solution: remove it

linetabsize_col() calls init_chartabsize_arg() with 0 as "lnum", so
cts.cts_has_prop_with_text is always FALSE.

closes: #PR

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
  • Loading branch information
zeertzjq authored and chrisbra committed Aug 13, 2023
1 parent 4a8eb6e commit d3515a1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
8 changes: 0 additions & 8 deletions src/charset.c
Original file line number Diff line number Diff line change
Expand Up @@ -769,14 +769,6 @@ linetabsize_col(int startcol, char_u *s)
init_chartabsize_arg(&cts, curwin, 0, startcol, s, s);
while (*cts.cts_ptr != NUL)
cts.cts_vcol += lbr_chartabsize_adv(&cts);
#ifdef FEAT_PROP_POPUP
if (cts.cts_has_prop_with_text && cts.cts_ptr == cts.cts_line)
{
// check for virtual text in an empty line
(void)lbr_chartabsize_adv(&cts);
cts.cts_vcol += cts.cts_cur_text_width;
}
#endif
clear_chartabsize_arg(&cts);
return (int)cts.cts_vcol;
}
Expand Down
2 changes: 2 additions & 0 deletions src/version.c
Original file line number Diff line number Diff line change
Expand Up @@ -695,6 +695,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
/**/
1711,
/**/
1710,
/**/
Expand Down

0 comments on commit d3515a1

Please sign in to comment.