aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/ops.c
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2021-09-18 00:24:39 +0200
committerGitHub <noreply@github.com>2021-09-18 00:24:39 +0200
commit1f49268c46fcbe65f7e2e2cb620e6f51c059cf9e (patch)
treee7cea7cc17ce0e5004ef040f5d0ffa1384c06ea9 /src/nvim/ops.c
parentede5695eb194e9b607421415525177888b447753 (diff)
downloadrneovim-1f49268c46fcbe65f7e2e2cb620e6f51c059cf9e.tar.gz
rneovim-1f49268c46fcbe65f7e2e2cb620e6f51c059cf9e.tar.bz2
rneovim-1f49268c46fcbe65f7e2e2cb620e6f51c059cf9e.zip
refactor: convert TRUE/FALSE to true/false (#15660)
Diffstat (limited to 'src/nvim/ops.c')
-rw-r--r--src/nvim/ops.c20
1 files changed, 9 insertions, 11 deletions
diff --git a/src/nvim/ops.c b/src/nvim/ops.c
index e344bb5e77..12fb8439f1 100644
--- a/src/nvim/ops.c
+++ b/src/nvim/ops.c
@@ -765,9 +765,9 @@ char_u *get_expr_line(void)
return expr_copy;
}
- ++nested;
- rv = eval_to_string(expr_copy, NULL, TRUE);
- --nested;
+ nested++;
+ rv = eval_to_string(expr_copy, NULL, true);
+ nested--;
xfree(expr_copy);
return rv;
}
@@ -1237,16 +1237,14 @@ int insert_reg(int regname, bool literally_arg)
return retval;
}
-/*
- * Stuff a string into the typeahead buffer, such that edit() will insert it
- * literally ("literally" TRUE) or interpret is as typed characters.
- */
-static void stuffescaped(const char *arg, int literally)
+/// Stuff a string into the typeahead buffer, such that edit() will insert it
+/// literally ("literally" true) or interpret is as typed characters.
+static void stuffescaped(const char *arg, bool literally)
{
while (*arg != NUL) {
// Stuff a sequence of normal ASCII characters, that's fast. Also
// stuff K_SPECIAL to get the effect of a special key when "literally"
- // is TRUE.
+ // is true.
const char *const start = arg;
while ((*arg >= ' ' && *arg < DEL) || ((uint8_t)(*arg) == K_SPECIAL
&& !literally)) {
@@ -2890,7 +2888,7 @@ void do_put(int regname, yankreg_T *reg, int dir, long count, int flags)
int indent;
int orig_indent = 0; // init for gcc
int indent_diff = 0; // init for gcc
- int first_indent = TRUE;
+ bool first_indent = true;
int lendiff = 0;
pos_T old_pos;
char_u *insert_string = NULL;
@@ -3487,7 +3485,7 @@ void do_put(int regname, yankreg_T *reg, int dir, long count, int flags)
} else if (first_indent) {
indent_diff = orig_indent - get_indent();
indent = orig_indent;
- first_indent = FALSE;
+ first_indent = false;
} else if ((indent = get_indent() + indent_diff) < 0) {
indent = 0;
}