关闭搜索包装:
set nowrapscan
Run Code Online (Sandbox Code Playgroud)
它会给出错误并停在缓冲区的顶部和底部:
E384: search hit TOP without match for: set
E385: search hit BOTTOM without match for: set
Run Code Online (Sandbox Code Playgroud)
来自:h wrapscan:(默认开启)
Searches wrap around the end of the file. Also applies to ]s and
[s, searching for spelling mistakes.
Run Code Online (Sandbox Code Playgroud)