On 21.10.19 21:57, Yegappan Lakshmanan wrote:
> Hi,
>
> On Mon, Oct 21, 2019 at 12:12 PM D. Ben Knoble
...
>
> Hi,
>
> Can you try the attached patch?
>
> Thanks,
> Yegappan
>

Yegappan,

thank you for providing a patch.

It seems the patch didn't make it to GitHub. I pinged Ben & Dedowsdi via
stackexchange. Hope they see it.

I tested your patch in three ways:

1) :cdo s/TEST/HELLO/

This will always fail, as there is no string "TEST" in any line. This
error was ignored and :cdo worked on all lines.

Is that intended?

2) Calling a function from :cdo

I build a qf list by :vimgrep for the word "dog". The function should
replace "dog" with "cat". On the third invocation it throws an exception.

2.1) :cdo call Test_cdo()

The first two entries were replaced and on the third entry a exception
was thrown. Processing stops immediately. All other "dog"s were unchanged.

2.2) :cdo silent call Test_cdo()

Acts like 2.1

2.3) :cdo silent! call Test_cdo()

Ignores the exception and works on all entries of the qf list.

3) :cdo echo x

The variable x is not defined. This was detected and the command was
executed for the first entry of the qf list.
With 'silent!' it processes all entries from the list.

I'm not sure if the behavior in the first test case is intended. In the
other two cases it worked like I expected.

Regards,
Ralf



--
--
You received this message from the "vim_dev" 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_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/8a46e92c-7774-17fd-5698-5b63e4e054fa%40gmx.de.

Raspunde prin e-mail lui