patch 8.2.3908: cannot use a script-local function for 'foldtext'
Problem: Cannot use a script-local function for 'foldtext'.
Solution: Expand "s:" and "<SID>". (Yegappan Lakshmanan, closes #9411)
diff --git a/runtime/doc/fold.txt b/runtime/doc/fold.txt
index 56c3c75..cac76ba 100644
--- a/runtime/doc/fold.txt
+++ b/runtime/doc/fold.txt
@@ -122,7 +122,7 @@
backwards for a line for which the fold level is defined. This can be slow.
If the 'foldexpr' expression starts with s: or |<SID>|, then it is replaced
-with the script ID (|local-function|). Example: >
+with the script ID (|local-function|). Examples: >
set foldexpr=s:MyFoldExpr()
set foldexpr=<SID>SomeFoldExpr()
<
@@ -529,6 +529,11 @@
When there is room after the text, it is filled with the character specified
by 'fillchars'.
+If the 'foldtext' expression starts with s: or |<SID>|, then it is replaced
+with the script ID (|local-function|). Examples: >
+ set foldtext=s:MyFoldText()
+ set foldtext=<SID>SomeFoldText()
+<
Note that backslashes need to be used for characters that the ":set" command
handles differently: Space, backslash and double-quote. |option-backslash|