VIM handles strings with a look around to facilitate complex deletion and replacement operations
For an explanation of the look, please refer to Yurii's "proficient in regular expression" book.
If you have the following string:
Smallcat
Smalldog
Mysmallcat
Smallcat_lili
\@= Order
Eg: find the characters behind the cat small
/small\ (cat\) \@=
\@! Order negative Look around
Eg: find characters that are not followed by cat small
Small\ (cat\) \@.
\@<= Reverse
Eg: Look up the cat in front of the small
\ (small\) \@<=cat
\@<! Reverse negation
Eg: Find Cat in front that is not small
\ (small\) \@<. Cat
\@> Curing Group
\% (atom\) non-capture bracket
This means that this grouping is not captured and does not record the expression within this bracket:
%s/\% (cat\) _\ (lili\)/\1/gc
Reference documentation
http://blog.csdn.net/lxcnn/article/details/4304754http://blog.csdn.net/lxcnn/article/details/4304754