Possible bug with search command invoked with foldd

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Possible bug with search command invoked with foldd

Jean Johner
Hello,
The following is extracted from the thread "Reduce search to unfolded
parts" in vim_use mailing list.

I still have a problem with the foldd command.
Applied to a file without any fold, the following commands should
behave exactly the same:

:%s/foobar/foo/gc
:foldd s/foobar/foo/gc

Please create a file with the two following lines:
      dimension pfusm(10),parmat(10)
      data nbpfusm/1/,pfusm/200.e6,9*0./
Applying the following command (from the top):
:foldd s/pfus/pfas/gc
and typing y 3 times gives the answer:
3 substitutioons on 2 lines (OK)
Going back to the top (gg) and typing:
:foldd s/pfas/pfus/gc
and typing y 3 times gives the answer:
6 substitutioons on 4 lines (not OK)

Now, if you do exactly the same with
:%s/pfus/pfas/gc
then
:%s/pfas/pfus/gc
you get "3 substitutions on 2 lines" twice, which is OK.
It looks like a bug.

Can you reproduce that.

Best regards.

Jean Johner


--
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
Reply | Threaded
Open this post in threaded view
|

Re: Possible bug with search command invoked with foldd

Jean Johner
Sorry, the title of this thread should be read:

"Possible bug with substitute command invoked with foldd"

Jean Johner

--
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
Reply | Threaded
Open this post in threaded view
|

[patch] Re: Possible bug with search command invoked with foldd

Lech Lorens
In reply to this post by Jean Johner
On 20-Feb-2010 Jean Johner <[hidden email]> wrote:
> Hello,
[...]
> It looks like a bug.
>
> Can you reproduce that.
>
> Best regards.
>
> Jean Johner

The attached patch corrects the erroneous message.

--
Cheers,
Lech

--
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

foldd-subst-message.patch (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Possible bug with search command invoked with foldd

Jean Johner
On Mar 13, 12:26 am, Lech Lorens <[hidden email]> wrote:
> The attached patch corrects the erroneous message.
>  foldd-subst-message.patch
> 1KViewDownload

Hi Lech,

I have applied your patch to vim7.2.394. It works (congratulations!)

Some questions (since I am new to Vim):
I guess this patch is part of the unofficial vim patches
1) Where is this patch available? (besides the upper message)
2) As it is a correction to a standard vim command (not an extension),
is it envisaged this patch to be included into an official vim patch?
3) If yes, when?

Best regards,

Jean Johner

--
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
Reply | Threaded
Open this post in threaded view
|

Re: Possible bug with search command invoked with foldd

Lech Lorens
On 16-Mar-2010 Jean Johner <[hidden email]> wrote:
> I guess this patch is part of the unofficial vim patches
> 1) Where is this patch available? (besides the upper message)
> 2) As it is a correction to a standard vim command (not an extension),
> is it envisaged this patch to be included into an official vim patch?
> 3) If yes, when?

1. Nowhere.
2,3. Bram Moolenaar is the author of Vim, its maintainer and the person
who reviews the patches and makes the final decision what goes in and
what does not. Only Bram can answer these questions.

--
Cheers,
Lech

--
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
Reply | Threaded
Open this post in threaded view
|

Re: Possible bug with search command invoked with foldd

Jean Johner
On Mar 16, 9:53 pm, Lech Lorens <[hidden email]> wrote:
> 2,3. Bram Moolenaar is the author of Vim, its maintainer and the person
> who reviews the patches and makes the final decision what goes in and
> what does not. Only Bram can answer these questions.

OK.
Please, Bram, do consider including the above wonderful patch into one
of your official patches.
No urgence however.

Best regards

Jean Johner

--
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
Reply | Threaded
Open this post in threaded view
|

Re: Possible bug with search command invoked with foldd

Jean Johner
In reply to this post by Lech Lorens
It seems that the correction is properly taken into account in patch
409.
Thank you, Lech and Bram.

Best regards
Jean

--
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

To unsubscribe from this group, send email to vim_dev+unsubscribegooglegroups.com or reply to this email with the words "REMOVE ME" as the subject.