我经常在vim插件中看到类似这样的东西:
let g:variable
let b:variable
let l:variable
Run Code Online (Sandbox Code Playgroud)
我对vim文档进行了长时间的研究,并在互联网上对这些字母'g','b','l'进行了长时间的研究,但我发现了这一点.
那么这些字母对应的是什么?什么是完整的信件清单?
Xym*_*ech 104
看到 :help internal-variables
它列出了以下类型:
(nothing) In a function: local to a function; otherwise: global buffer-variable b: Local to the current buffer. window-variable w: Local to the current window. tabpage-variable t: Local to the current tab page. global-variable g: Global. local-variable l: Local to a function. script-variable s: Local to a :source'ed Vim script. function-argument a: Function argument (only inside a function). vim-variable v: Global, predefined by Vim.