To: vim_dev@googlegroups.com Subject: Patch 9.0.0038 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 9.0.0038 (after 9.0.0036) Problem: 'listchars' test fails. Solution: Use window-local value after setting the global value Files: src/optionstr.c *** ../vim-9.0.0037/src/optionstr.c 2022-07-04 17:34:06.386292140 +0100 --- src/optionstr.c 2022-07-04 18:01:31.393287728 +0100 *************** *** 1313,1327 **** tabpage_T *tp; win_T *wp; ! // The current window is set to use the global 'listchars' value. ! // So clear the window-local value. if (!(opt_flags & OPT_GLOBAL)) clear_string_option(&curwin->w_p_lcs); FOR_ALL_TAB_WINDOWS(tp, wp) // If no error was returned above, we don't expect an error // here, so ignore the return value. ! if (*wp->w_p_lcs == NUL) ! (void)set_chars_option(wp, &wp->w_p_lcs); redraw_all_later(NOT_VALID); } --- 1313,1328 ---- tabpage_T *tp; win_T *wp; ! // If the current window is set to use the global 'listchars' ! // value, clear the window-local value. if (!(opt_flags & OPT_GLOBAL)) clear_string_option(&curwin->w_p_lcs); FOR_ALL_TAB_WINDOWS(tp, wp) + // If the current window has a local value need to apply it + // again, it was changed when setting the global value. // If no error was returned above, we don't expect an error // here, so ignore the return value. ! (void)set_chars_option(wp, &wp->w_p_lcs); redraw_all_later(NOT_VALID); } *************** *** 1339,1353 **** tabpage_T *tp; win_T *wp; ! // The current window is set to use the global 'fillchars' value. ! // So clear the window-local value. if (!(opt_flags & OPT_GLOBAL)) clear_string_option(&curwin->w_p_fcs); FOR_ALL_TAB_WINDOWS(tp, wp) // If no error was returned above, we don't expect an error // here, so ignore the return value. ! if (*wp->w_p_fcs == NUL) ! (void)set_chars_option(wp, &wp->w_p_fcs); redraw_all_later(NOT_VALID); } --- 1340,1355 ---- tabpage_T *tp; win_T *wp; ! // If the current window is set to use the global 'fillchars' ! // value clear the window-local value. if (!(opt_flags & OPT_GLOBAL)) clear_string_option(&curwin->w_p_fcs); FOR_ALL_TAB_WINDOWS(tp, wp) + // If the current window has a local value need to apply it + // again, it was changed when setting the global value. // If no error was returned above, we don't expect an error // here, so ignore the return value. ! (void)set_chars_option(wp, &wp->w_p_fcs); redraw_all_later(NOT_VALID); } *** ../vim-9.0.0037/src/version.c 2022-07-04 17:46:18.562074259 +0100 --- src/version.c 2022-07-04 18:01:49.489270365 +0100 *************** *** 737,738 **** --- 737,740 ---- { /* Add new patch number below this line */ + /**/ + 38, /**/ -- hundred-and-one symptoms of being an internet addict: 47. You are so familiar with the WWW that you find the search engines useless. /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///