Hello,
I have a Vim plugin that needs to access a persistent variable stored in
viminfo. The viminfo file is however loaded _after_ the plugins therefore the
script has to use the VimEnter autocommand to get to the global variable. I
have wrapped this autocommand in a single-use augroup, which is removed as a
part of the autocommand callback as follows:
function onVimStartup()
" apply global variable from viminfo
autocmd! TmpGroup
augroup! TmpGroup
endfunction
augroup TmpGroup
au VimEnter * call onVimStartup()
augroup END
After patch 2117 the plugin started displaying the W19 warning
"W19: Deleting augroup that is still in use" and the ":augroup"
command in Vim shows "--Deleted--" in place of the TmpGroup.
Is this a bug or an expected behavior? The TmpGroup is already
empty at the "augroup!" line although its autocommand is still executing.
Would it be possible to allow the augroup removal complete when augroup
is already empty?
If not - is there some other way how to do a self-destructing VimEnter
autocommand?
Thank you,
Pavol
--
--
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.