On 2024-01-08, Yegappan Lakshmanan wrote:
> Hi Gary,
> 
> On Mon, Jan 8, 2024 at 12:14 PM Gary Johnson wrote:
> 
>     On 2024-01-07, Yegappan Lakshmanan wrote:
> 
>     > To demonstrate the use of the new matchbufline() function, I have created
>     > the following script.  This does search text completion from the list of
>     words
>     > in the current buffer.  After typing a few letters in the "/" prompt, if
>     you
>     > press
>     > Tab, it will complete the word from the current buffer.  If you press Tab
>     > again,
>     > then it will go to the next match.  If you press Shift-Tab, it will go
>     back to
>     > the previous match.
> 
>     I saved your script to a file and sourced it, but it gives me an
>     error.
> 
>         Error detected while processing /home/gary/.vim/match_tab.vim:
>         line    9:
>         E1171: Missing } after inline function
> 
>     Line 9 is:
> 
>         def SearchComplete(forward: bool): string
> 
> 
> 
> I am not sure what is wrong from the above error message.  In case there
> is a cut/paste error, can you please try the attached file?
Hi Yegappan,
Thank you.  That fixed the problem.  I had copied your script from
your original posting by decode-saving your message from mutt, then
deleting the text before and after the script.  It turns out that
the leading spaces in that copy included non-breaking space
characters, 0xa0, which somehow confused Vim's parser.
I did have to convert your attachment from DOS to Unix line endings,
but that was immediately apparent and not a problem.
Regards,
Gary
-- 
-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
--- 
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/20240108230219.GK4044%40phoenix.
Monday, January 8, 2024
Subscribe to:
Post Comments (Atom)
 
No comments:
Post a Comment