aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/option.c
diff options
context:
space:
mode:
authordundargoc <33953936+dundargoc@users.noreply.github.com>2021-09-29 19:48:50 +0200
committerGitHub <noreply@github.com>2021-09-29 19:48:50 +0200
commitd90fb1c0bfc1e64c783c385a79e7de87013dadba (patch)
tree5a27261e9aed7ebdb95122fc888811ea5f903cc8 /src/nvim/option.c
parentec4731d982031e363a59efd4566fc72234bb43c8 (diff)
downloadrneovim-d90fb1c0bfc1e64c783c385a79e7de87013dadba.tar.gz
rneovim-d90fb1c0bfc1e64c783c385a79e7de87013dadba.tar.bz2
rneovim-d90fb1c0bfc1e64c783c385a79e7de87013dadba.zip
Refactor/uncrustify (#15790)
* refactor: format with uncrustify * fixup(dundar): fix functions comments * fixup(dundar): remove space between variable and ++/-- * fixup(dundar): better workaround for macro attributes This is done to be able to better use uncrustify rules for macros * fixup(justin): make preprocessors follow neovim style guide
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r--src/nvim/option.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c
index 8bdba82b67..5646a62cd4 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -374,11 +374,11 @@ void set_init_1(bool clean_arg)
* temp files.
*/
{
-# ifdef UNIX
+#ifdef UNIX
static char *(names[4]) = { "", "TMPDIR", "TEMP", "TMP" };
-# else
+#else
static char *(names[3]) = { "TMPDIR", "TEMP", "TMP" };
-# endif
+#endif
garray_T ga;
opt_idx = findoption("backupskip");
@@ -386,16 +386,16 @@ void set_init_1(bool clean_arg)
for (size_t n = 0; n < ARRAY_SIZE(names); n++) {
bool mustfree = true;
char *p;
-# ifdef UNIX
+#ifdef UNIX
if (*names[n] == NUL) {
-# ifdef __APPLE__
+# ifdef __APPLE__
p = "/private/tmp";
-# else
+# else
p = "/tmp";
-# endif
+# endif
mustfree = false;
} else
-# endif
+#endif
{
p = vim_getenv(names[n]);
}
@@ -5831,10 +5831,10 @@ static char_u *get_varp(vimoption_T *p)
return (char_u *)&(curbuf->b_p_cms);
case PV_CPT:
return (char_u *)&(curbuf->b_p_cpt);
-# ifdef BACKSLASH_IN_FILENAME
+#ifdef BACKSLASH_IN_FILENAME
case PV_CSL:
return (char_u *)&(curbuf->b_p_csl);
-# endif
+#endif
case PV_CFU:
return (char_u *)&(curbuf->b_p_cfu);
case PV_OFU:
@@ -6179,9 +6179,9 @@ void buf_copy_options(buf_T *buf, int flags)
buf->b_p_inf = p_inf;
buf->b_p_swf = cmdmod.noswapfile ? false : p_swf;
buf->b_p_cpt = vim_strsave(p_cpt);
-# ifdef BACKSLASH_IN_FILENAME
+#ifdef BACKSLASH_IN_FILENAME
buf->b_p_csl = vim_strsave(p_csl);
-# endif
+#endif
buf->b_p_cfu = vim_strsave(p_cfu);
buf->b_p_ofu = vim_strsave(p_ofu);
buf->b_p_tfu = vim_strsave(p_tfu);