diff options
author | dundargoc <gocdundar@gmail.com> | 2023-12-16 22:14:28 +0100 |
---|---|---|
committer | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2023-12-19 11:43:21 +0100 |
commit | 7f6b775b45de5011ff1c44e63e57551566d80704 (patch) | |
tree | 54eab8482051d2d1a958fcf9f6c9bcbb02827717 /src/nvim/indent.c | |
parent | 693aea0e9e1032aee85d56c1a3f33e0811dbdc18 (diff) | |
download | rneovim-7f6b775b45de5011ff1c44e63e57551566d80704.tar.gz rneovim-7f6b775b45de5011ff1c44e63e57551566d80704.tar.bz2 rneovim-7f6b775b45de5011ff1c44e63e57551566d80704.zip |
refactor: use `bool` to represent boolean values
Diffstat (limited to 'src/nvim/indent.c')
-rw-r--r-- | src/nvim/indent.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nvim/indent.c b/src/nvim/indent.c index 61422561e0..adb609358d 100644 --- a/src/nvim/indent.c +++ b/src/nvim/indent.c @@ -434,7 +434,7 @@ int get_indent_str_vtab(const char *ptr, OptInt ts, colnr_T *vts, bool list) /// @param size measured in spaces /// /// @return true if the line was changed. -int set_indent(int size, int flags) +bool set_indent(int size, int flags) { char *newline; char *oldline; @@ -442,7 +442,7 @@ int set_indent(int size, int flags) int doit = false; int ind_done = 0; // Measured in spaces. int tab_pad; - int retval = false; + bool retval = false; // Number of initial whitespace chars when 'et' and 'pi' are both set. int orig_char_len = -1; @@ -1094,14 +1094,14 @@ void ex_retab(exarg_T *eap) /// Get indent level from 'indentexpr'. int get_expr_indent(void) { - int use_sandbox = was_set_insecurely(curwin, kOptIndentexpr, OPT_LOCAL); + bool use_sandbox = was_set_insecurely(curwin, kOptIndentexpr, OPT_LOCAL); const sctx_T save_sctx = current_sctx; // Save and restore cursor position and curswant, in case it was changed // * via :normal commands. pos_T save_pos = curwin->w_cursor; colnr_T save_curswant = curwin->w_curswant; - int save_set_curswant = curwin->w_set_curswant; + bool save_set_curswant = curwin->w_set_curswant; set_vim_var_nr(VV_LNUM, (varnumber_T)curwin->w_cursor.lnum); if (use_sandbox) { |