From 80a566b55fd90fb49271e04106ddafb8ccb470cb Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Thu, 8 Sep 2022 08:50:43 +0800 Subject: [PATCH 1/2] vim-patch:9.0.0410: struct member cts_lnum is unused Problem: Struct member cts_lnum is unused. Solution: Delete it. https://github.com/vim/vim/commit/d7633114af2365e32080b61af473db347a3489c2 --- src/nvim/plines.c | 1 - src/nvim/plines.h | 1 - 2 files changed, 2 deletions(-) diff --git a/src/nvim/plines.c b/src/nvim/plines.c index c676dcddbd..176f86c691 100644 --- a/src/nvim/plines.c +++ b/src/nvim/plines.c @@ -292,7 +292,6 @@ void init_chartabsize_arg(chartabsize_T *cts, win_T *wp, linenr_T lnum, colnr_T char *ptr) { cts->cts_win = wp; - cts->cts_lnum = lnum; cts->cts_vcol = col; cts->cts_line = line; cts->cts_ptr = ptr; diff --git a/src/nvim/plines.h b/src/nvim/plines.h index 7b228f3e91..f463d82f10 100644 --- a/src/nvim/plines.h +++ b/src/nvim/plines.h @@ -6,7 +6,6 @@ // Argument for lbr_chartabsize(). typedef struct { win_T *cts_win; - linenr_T cts_lnum; // zero when not using text properties char *cts_line; // start of the line char *cts_ptr; // current position in line From 06f9da547cbcc0b12c2d946a0abe0aee0bad4011 Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Thu, 8 Sep 2022 08:52:45 +0800 Subject: [PATCH 2/2] vim-patch:9.0.0412: compiler warning for unused argument Problem: Compiler warning for unused argument. Solution: Add UNUSED. https://github.com/vim/vim/commit/e5a420fb33518e08313f653f3031bc36f949e086 --- src/nvim/plines.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/nvim/plines.c b/src/nvim/plines.c index 176f86c691..cbde0cfff9 100644 --- a/src/nvim/plines.c +++ b/src/nvim/plines.c @@ -288,8 +288,8 @@ unsigned int win_linetabsize(win_T *wp, linenr_T lnum, char_u *line, colnr_T len /// /// "line" is the start of the line, "ptr" is the first relevant character. /// When "lnum" is zero do not use text properties that insert text. -void init_chartabsize_arg(chartabsize_T *cts, win_T *wp, linenr_T lnum, colnr_T col, char *line, - char *ptr) +void init_chartabsize_arg(chartabsize_T *cts, win_T *wp, linenr_T lnum FUNC_ATTR_UNUSED, + colnr_T col, char *line, char *ptr) { cts->cts_win = wp; cts->cts_vcol = col;