]> granicus.if.org Git - vim/commitdiff
patch 9.0.0880: preprocessor indenting is off v9.0.0880
authorK.Takata <kentkt@csc.jp>
Mon, 14 Nov 2022 15:31:07 +0000 (15:31 +0000)
committerBram Moolenaar <Bram@vim.org>
Mon, 14 Nov 2022 15:31:07 +0000 (15:31 +0000)
Problem:    Preprocessor indenting is off.
Solution:   Adjust preprocessor indentation. (Ken Takata, closes #11546)

src/cindent.c
src/cmdexpand.c
src/gui.c
src/if_perl.xs
src/if_python3.c
src/os_win32.c
src/version.c

index 15b459cd6fd4648a843b6105a1279318bfbfd51b..105e08cc8cd838fbf51e48aedf1d122b9d1d07d2 100644 (file)
@@ -4145,11 +4145,11 @@ in_cinkeys(
     void
 do_c_expr_indent(void)
 {
-# ifdef FEAT_EVAL
+#ifdef FEAT_EVAL
     if (*curbuf->b_p_inde != NUL)
        fixthisline(get_expr_indent);
     else
-# endif
+#endif
        fixthisline(get_c_indent);
 }
 
index 1f4791aa39f3931cc8738ac2d272e2de84f64494..4f12625388ce0c69e1cc30f159ffdd44696e0b9a 100644 (file)
@@ -2756,7 +2756,7 @@ get_behave_arg(expand_T *xp UNUSED, int idx)
     return NULL;
 }
 
-# ifdef FEAT_EVAL
+#ifdef FEAT_EVAL
 /*
  * Function given to ExpandGeneric() to obtain the possible arguments of the
  * ":breakadd {expr, file, func, here}" command.
@@ -3020,10 +3020,10 @@ ExpandFromContext(
        char *directories[] = {"syntax", "indent", "ftplugin", NULL};
        return ExpandRTDir(pat, 0, numMatches, matches, directories);
     }
-# if defined(FEAT_EVAL)
+#if defined(FEAT_EVAL)
     if (xp->xp_context == EXPAND_USER_LIST)
        return ExpandUserList(xp, matches, numMatches);
-# endif
+#endif
     if (xp->xp_context == EXPAND_PACKADD)
        return ExpandPackAddDir(pat, numMatches, matches);
 
@@ -3057,10 +3057,10 @@ ExpandFromContext(
        ret = ExpandSettings(xp, &regmatch, pat, numMatches, matches, fuzzy);
     else if (xp->xp_context == EXPAND_MAPPINGS)
        ret = ExpandMappings(pat, &regmatch, numMatches, matches);
-# if defined(FEAT_EVAL)
+#if defined(FEAT_EVAL)
     else if (xp->xp_context == EXPAND_USER_DEFINED)
        ret = ExpandUserDefined(pat, xp, &regmatch, matches, numMatches);
-# endif
+#endif
     else
        ret = ExpandOther(pat, xp, &regmatch, matches, numMatches);
 
@@ -3168,7 +3168,7 @@ ExpandGeneric(
        else
            ((char_u **)ga.ga_data)[ga.ga_len] = str;
 
-# ifdef FEAT_MENU
+#ifdef FEAT_MENU
        if (func == get_menu_names)
        {
            // test for separator added by get_menu_names()
@@ -3176,7 +3176,7 @@ ExpandGeneric(
            if (*str == '\001')
                *str = '.';
        }
-# endif
+#endif
 
        ++ga.ga_len;
     }
@@ -3350,11 +3350,11 @@ expand_shellcmd(
     hash_init(&found_ht);
     for (s = path; ; s = e)
     {
-# if defined(MSWIN)
+#if defined(MSWIN)
        e = vim_strchr(s, ';');
-# else
+#else
        e = vim_strchr(s, ':');
-# endif
+#endif
        if (e == NULL)
            e = s + STRLEN(s);
 
@@ -3396,7 +3396,7 @@ expand_shellcmd(
     return OK;
 }
 
-# if defined(FEAT_EVAL)
+#if defined(FEAT_EVAL)
 /*
  * Call "user_expand_func()" to invoke a user defined Vim script function and
  * return the result (either a string, a List or NULL).
@@ -3580,7 +3580,7 @@ ExpandUserList(
     *numMatches = ga.ga_len;
     return OK;
 }
-# endif
+#endif
 
 /*
  * Expand "file" for all comma-separated directories in "path".
@@ -3613,14 +3613,14 @@ globpath(
        copy_option_part(&path, buf, MAXPATHL, ",");
        if (STRLEN(buf) + STRLEN(file) + 2 < MAXPATHL)
        {
-# if defined(MSWIN)
+#if defined(MSWIN)
            // Using the platform's path separator (\) makes vim incorrectly
            // treat it as an escape character, use '/' instead.
            if (*buf != NUL && !after_pathsep(buf, buf + STRLEN(buf)))
                STRCAT(buf, "/");
-# else
+#else
            add_pathsep(buf);
-# endif
+#endif
            STRCAT(buf, file);
            if (ExpandFromContext(&xpc, buf, &p, &num_p,
                             WILD_SILENT|expand_options) != FAIL && num_p > 0)
@@ -3828,10 +3828,10 @@ wildmenu_process_key_filenames(cmdline_info_T *cclp, int key, expand_T *xp)
            if (has_mbyte)
                j -= (*mb_head_off)(cclp->cmdbuff, cclp->cmdbuff + j);
            if (vim_ispathsep(cclp->cmdbuff[j])
-# ifdef BACKSLASH_IN_FILENAME
+#ifdef BACKSLASH_IN_FILENAME
                    && vim_strchr((char_u *)" *?[{`$%#",
                        cclp->cmdbuff[j + 1]) == NULL
-# endif
+#endif
               )
            {
                if (found)
index dbd8d3fcc127e4ec458caa05dd442af676519015..88c0a1345317138d98ce3772e8659793df25898f 100644 (file)
--- a/src/gui.c
+++ b/src/gui.c
@@ -230,10 +230,10 @@ gui_do_fork(void)
     int                exit_status;
     pid_t      pid = -1;
 
-#if defined(FEAT_RELTIME) && defined(HAVE_TIMER_CREATE)
+# if defined(FEAT_RELTIME) && defined(HAVE_TIMER_CREATE)
     // a timer is not carried forward
     delete_timer();
-#endif
+# endif
 
     // Setup a pipe between the child and the parent, so that the parent
     // knows when the child has done the setsid() call and is allowed to
index 08e0e02f32674dc3d75ad84d35735cc3f1e1812b..34315be7196371e74cac6a64d897a7180dea4a8c 100644 (file)
 
 // Suppress Infinite warnings when compiling XS modules under macOS 12 Monterey.
 #if defined(__clang__) && defined(__clang_major__) && __clang_major__ > 11
-#pragma clang diagnostic ignored "-Wcompound-token-split-by-macro"
+# pragma clang diagnostic ignored "-Wcompound-token-split-by-macro"
 #endif
 
 /* Compatibility hacks over */
index d06f66210734f9773f99f3ad9964702adcbf3ab9..e0c546a3f7db65a4a34648fa29c1fac24a0970dc 100644 (file)
@@ -83,7 +83,7 @@
 
 // Suppress Python 3.11 depreciations to see useful warnings
 #if defined(__clang__) && defined(__clang_major__) && __clang_major__ > 11
-#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+# pragma clang diagnostic ignored "-Wdeprecated-declarations"
 #endif
 
 // Python 3 does not support CObjects, always use Capsules
index c68a9732bdc7f078cdb6d2ddd2e28f3ca64e9e84..36051f4852bcefb0c68aff67e6f2e2c6cab84a26 100644 (file)
@@ -1262,7 +1262,7 @@ decode_mouse_wheel(MOUSE_EVENT_RECORD *pmer)
     g_xMouse = pmer->dwMousePosition.X;
     g_yMouse = pmer->dwMousePosition.Y;
 
-#ifdef FEAT_PROP_POPUP
+# ifdef FEAT_PROP_POPUP
     int lcol = g_xMouse;
     int lrow = g_yMouse;
     win_T *wp = mouse_find_win(&lrow, &lcol, FIND_POPUP);
@@ -1294,7 +1294,7 @@ decode_mouse_wheel(MOUSE_EVENT_RECORD *pmer)
        out_flush();
        return;
     }
-#endif
+# endif
     mouse_col = g_xMouse;
     mouse_row = g_yMouse;
 
@@ -6059,9 +6059,9 @@ insert_lines(unsigned cLines)
 
     fill.Char.AsciiChar = ' ';
     if (!(vtp_working
-#ifdef FEAT_TERMGUICOLORS
+# ifdef FEAT_TERMGUICOLORS
                && (p_tgc || t_colors >= 256)
-#endif
+# endif
         ))
        fill.Attributes = g_attrCurrent;
     else
@@ -6187,9 +6187,9 @@ gotoxy(
        return;
 
     if (!(vtp_working
-#ifdef FEAT_TERMGUICOLORS
+# ifdef FEAT_TERMGUICOLORS
                && (p_tgc || t_colors >= 256)
-#endif
+# endif
         ))
     {
        // There are reports of double-width characters not displayed
@@ -6435,9 +6435,9 @@ write_chars(
     }
 
     if (!(vtp_working
-#ifdef FEAT_TERMGUICOLORS
+# ifdef FEAT_TERMGUICOLORS
            && (p_tgc || t_colors >= 256)
-#endif
+# endif
        ))
     {
        FillConsoleOutputAttribute(g_hConOut, g_attrCurrent, cells,
@@ -6479,9 +6479,9 @@ write_chars(
 
     // Cursor under VTP is always in the correct position, no need to reset.
     if (!(vtp_working
-#ifdef FEAT_TERMGUICOLORS
+# ifdef FEAT_TERMGUICOLORS
                && (p_tgc || t_colors >= 256)
-#endif
+# endif
         ))
        gotoxy(g_coord.X + 1, g_coord.Y + 1);
 
index acd8922c1d18e11e06eaf2f4854cbaa8be6abe11..f89595a84e4ac2366b9b28db3318ecd25d2075d9 100644 (file)
@@ -695,6 +695,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    880,
 /**/
     879,
 /**/