From bb35ed6aaaff097ae7b9ee3a6f35b11f808c5b89 Mon Sep 17 00:00:00 2001 From: Sean Dewar Date: Fri, 18 Jun 2021 09:47:01 +0100 Subject: [PATCH] fix(doc): don't use method call syntax in examples The method call syntax patches aren't ported yet. --- runtime/doc/map.txt | 2 +- runtime/doc/tips.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/runtime/doc/map.txt b/runtime/doc/map.txt index 77cbf7d9b7..10d503e180 100644 --- a/runtime/doc/map.txt +++ b/runtime/doc/map.txt @@ -855,7 +855,7 @@ Here is an example that counts the number of spaces with : > set clipboard= selection=inclusive let commands = #{line: "'[V']y", char: "`[v`]y", block: "`[\`]y"} silent exe 'noautocmd keepjumps normal! ' .. get(commands, a:type, '') - echom getreg('"')->count(' ') + echom count(getreg('"'), ' ') finally call setreg('"', reg_save) call setpos("'<", visual_marks_save[0]) diff --git a/runtime/doc/tips.txt b/runtime/doc/tips.txt index bcb2e48cbf..27b6ca2885 100644 --- a/runtime/doc/tips.txt +++ b/runtime/doc/tips.txt @@ -462,7 +462,7 @@ the current window, try this custom `:HelpCurwin` command: execute mods .. ' helpclose' let s:did_open_help = v:true endif - if !getcompletion(a:subject, 'help')->empty() + if !empty(getcompletion(a:subject, 'help')) execute mods .. ' edit ' .. &helpfile endif return 'help ' .. a:subject