diff options
author | dundargoc <gocdundar@gmail.com> | 2023-11-16 10:59:11 +0100 |
---|---|---|
committer | dundargoc <33953936+dundargoc@users.noreply.github.com> | 2023-11-20 19:57:09 +0100 |
commit | a6e3d93421ba13c407a96fac9cc01fa41ec7ad98 (patch) | |
tree | e84209969b11fe2f0dabcad00a271468b2199bc9 /src/nvim/option.c | |
parent | ec79ff893d5906e1f0d90953cffa535ffae47823 (diff) | |
download | rneovim-a6e3d93421ba13c407a96fac9cc01fa41ec7ad98.tar.gz rneovim-a6e3d93421ba13c407a96fac9cc01fa41ec7ad98.tar.bz2 rneovim-a6e3d93421ba13c407a96fac9cc01fa41ec7ad98.zip |
refactor: enable formatting for ternaries
This requires removing the "Inner expression should be aligned" rule
from clint as it prevents essentially any formatting regarding ternary
operators.
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r-- | src/nvim/option.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c index d64fb0c615..a920912452 100644 --- a/src/nvim/option.c +++ b/src/nvim/option.c @@ -618,12 +618,12 @@ void set_init_3(void) // set, but only if they have not been set before. int idx_srr = findoption("srr"); int do_srr = (idx_srr < 0) - ? false - : !(options[idx_srr].flags & P_WAS_SET); + ? false + : !(options[idx_srr].flags & P_WAS_SET); int idx_sp = findoption("sp"); int do_sp = (idx_sp < 0) - ? false - : !(options[idx_sp].flags & P_WAS_SET); + ? false + : !(options[idx_sp].flags & P_WAS_SET); size_t len = 0; char *p = (char *)invocation_path_tail(p_sh, &len); @@ -1645,8 +1645,8 @@ static char *option_expand(int opt_idx, char *val) // For 'spellsuggest' expand after "file:". expand_env_esc(val, NameBuff, MAXPATHL, (char **)options[opt_idx].var == &p_tags, false, - (char **)options[opt_idx].var == &p_sps ? "file:" : - NULL); + (char **)options[opt_idx].var == &p_sps ? "file:" + : NULL); if (strcmp(NameBuff, val) == 0) { // they are the same return NULL; } @@ -2281,8 +2281,8 @@ static const char *did_set_paste(optset_T *args FUNC_ATTR_UNUSED) xfree(buf->b_p_vsts_nopaste); } buf->b_p_vsts_nopaste = buf->b_p_vsts && buf->b_p_vsts != empty_string_option - ? xstrdup(buf->b_p_vsts) - : NULL; + ? xstrdup(buf->b_p_vsts) + : NULL; } // save global options |