aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/diff.c
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2023-02-12 18:48:49 +0100
committerGitHub <noreply@github.com>2023-02-12 18:48:49 +0100
commit5f72ab77bff1f1224be5cbbf9423bdddbc25635c (patch)
tree433c1cd4aca0b8d8b91a8b219327940957993bdb /src/nvim/diff.c
parent2b1c07a1d435b541c295afad13227ebb10def57e (diff)
downloadrneovim-5f72ab77bff1f1224be5cbbf9423bdddbc25635c.tar.gz
rneovim-5f72ab77bff1f1224be5cbbf9423bdddbc25635c.tar.bz2
rneovim-5f72ab77bff1f1224be5cbbf9423bdddbc25635c.zip
refactor: reduce scope of locals as per the style guide 3 (#22221)
refactor: reduce scope of locals as per the style guide
Diffstat (limited to 'src/nvim/diff.c')
-rw-r--r--src/nvim/diff.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/nvim/diff.c b/src/nvim/diff.c
index 3bdc965146..c5b28822d0 100644
--- a/src/nvim/diff.c
+++ b/src/nvim/diff.c
@@ -2652,8 +2652,7 @@ bool diff_find_change(win_T *wp, linenr_T lnum, int *startp, int *endp)
bool added = true;
linenr_T off = lnum - dp->df_lnum[idx];
- int i;
- for (i = 0; i < DB_COUNT; i++) {
+ for (int i = 0; i < DB_COUNT; i++) {
if ((curtab->tp_diffbuf[i] != NULL) && (i != idx)) {
// Skip lines that are not in the other change (filler lines).
if (off >= dp->df_count[i]) {