guotuofeng wrote:

> Suppose I have the following data: 
>   
> 4702103 BLOB: 1.dat 
> 4702103 BLOB: 3.dat 
> 4702104 BLOB: 4.dat 
> 4702104 BLOB: 5.dat 
> 4702106 BLOB: 6.dat 
>   
> And I want to remove duplicate item against the first column. The dedup data 
> should like:
>   
> 4702103 BLOB: 1.dat 
> 4702104 BLOB: 4.dat 
> 4702106 BLOB: 6.dat 
> 
> Then I write the following command:
> 
>   :g/\%(^\1.*$\n\)\@<=\(\d\+\).*$/d 
> 
> But it doesn't work if the regex engine is NFA. On the other hand, if I 
> choose use the old regex engine by:
> 
>   :set re=1 
> 
> Then I can get the expected results.

Might be the same problem as this item in the todo list:


- Using back reference before the capturing group sometimes works with the old
  engine, can we do this with the new engine?  E.g. with
  "/\%(<\1>\)\@<=.*\%(<\/\(\w\+\)>\)\@=" matching text inside HTML tags.

You might be able to make it work to match the digits in the first part
of the regexp.

-- 
hundred-and-one symptoms of being an internet addict:
134. You consider bandwidth to be more important than carats.

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

-- 
-- 
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].
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui