My vim 7.4 doesn't do this, but 7.3.547 does, so it looks like a bug that's been fixed.
Regards, John Little
I bet there is a bunch of scripts using 4-variable lets. Simple grep over the mess in $HOME/.vam (I hold all but my plugins there) found at least LaTeX_box plugin (ftplugin/latex-box/common.vim) and python-mode-klen (autoload/pymode/lint.vim, though it should have used line() and not getpos()). I do not know how many plugins do
let pos=getpos('.')
...
let [a,b,c,d]=pos
, use negative indices or something else. Why not use optional argumet to getpos() then? Note: optional argument should make it return a dictionary. 5 indistinguishable numbers are way too much.
Also check out winsaveview(), particularly .curswant key. Maybe there is no need to modify getpos().
> regards,
> Christian
>
> --
> --
> 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 vim_dev+u...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
On Aug 22, 2013 10:24 PM, "Christian Brabandt" <cbl...@256bit.org> wrote:
>
>
> On Do, 22 Aug 2013, Nikolay Pavlov wrote:
>
> > I bet there is a bunch of scripts using 4-variable lets. Simple grep over
>
> What do you mean with 4-variable lets?
let [a,b,c,d]=e
> > the mess in $HOME/.vam (I hold all but my plugins there) found at least
> > LaTeX_box plugin (ftplugin/latex-box/common.vim) and python-mode-klen
> > (autoload/pymode/lint.vim, though it should have used line() and not
> > getpos()). I do not know how many plugins do
> > let pos=getpos('.')
> > ...
> > let [a,b,c,d]=pos
> > , use negative indices or something else. Why not use optional argumet to
> > getpos() then? Note: optional argument should make it return a dictionary.
> > 5 indistinguishable numbers are way too much.
>
> Probably not. There not much difference to winsaveview() anymore. It was
> only a suggestion, though.
>
> regards,
> Christian
> --
> Frage an Radio Eriwan:
> Gibt es bei uns mehr Humor als anderswo?
> Radio Eriwan antwortet:
> Im Prinzip ja. Aber wir haben ihn auch nötig.
I think that winrestview() should be officially allowed to accept custom dictionary:
call winrestview({'curswant': 3})
seems to work fine. No "If you have changed the values the result is unpredictable.", but say what can be set this way and what combinations of keys should not be used.