commit 4dc337cda86f16a0f5976a4a8bf19da96309a484
parent 30a09bdd7e967153ed6de01bc92e33d014828814
Author: zeertzjq <zeertzjq@outlook.com>
Date: Fri, 21 Nov 2025 08:24:20 +0800
vim-patch:9.1.1924: 'commentstring' requires +folding feature (#36645)
Problem: 'commentstring' requires the +folding feature but is used in
contexts other than folding.
Solution: Remove the +folding feature guards from 'commentstring' and
make it available in all builds (Doug Kearns).
closes: vim/vim#18731
https://github.com/vim/vim/commit/a08030c9f729a133da552b5658e5b59c54581c79
Co-authored-by: Doug Kearns <dougkearns@gmail.com>
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/runtime/scripts/optwin.lua b/runtime/scripts/optwin.lua
@@ -231,6 +231,7 @@ local options_list = {
{ 'wrapmargin', N_ 'margin from the right in which to break a line' },
{ 'backspace', N_ 'specifies what <BS>, CTRL-W, etc. can do in Insert mode' },
{ 'comments', N_ 'definition of what comment lines look like' },
+ { 'commentstring', N_ 'template for comments; used to put the marker in' },
{ 'formatoptions', N_ 'list of flags that tell how automatic formatting works' },
{ 'formatlistpat', N_ 'pattern to recognize a numbered list' },
{ 'formatexpr', N_ 'expression used for "gq" to format lines' },
@@ -300,7 +301,6 @@ local options_list = {
{ 'foldclose', N_ 'set to "all" to close a fold when the cursor leaves it' },
{ 'foldopen', N_ 'specifies for which commands a fold will be opened' },
{ 'foldminlines', N_ 'minimum number of screen lines for a fold to be closed' },
- { 'commentstring', N_ 'template for comments; used to put the marker in' },
{ 'foldmethod', N_ 'folding type: "manual", "indent", "expr", "marker",\n"syntax" or "diff"' },
{ 'foldexpr', N_ 'expression used when \'foldmethod\' is "expr"' },
{ 'foldignore', N_ 'used to ignore lines when \'foldmethod\' is "indent"' },