Mercurial > vim
diff src/evalwindow.c @ 21703:22583b9d4efd v8.2.1401
patch 8.2.1401: cannot jump to the last used tabpage
Commit: https://github.com/vim/vim/commit/62a232506d06f6d1b3b7271801c907d6294dfe84
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Aug 9 14:04:42 2020 +0200
patch 8.2.1401: cannot jump to the last used tabpage
Problem: Cannot jump to the last used tabpage.
Solution: Add g<Tab> and tabpagnr('#'). (Yegappan Lakshmanan, closes https://github.com/vim/vim/issues/6661,
neovim #11626)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 09 Aug 2020 14:15:04 +0200 |
parents | 27401f09fe9b |
children | 0716b3299872 |
line wrap: on
line diff
--- a/src/evalwindow.c +++ b/src/evalwindow.c @@ -616,6 +616,9 @@ f_tabpagenr(typval_T *argvars UNUSED, ty { if (STRCMP(arg, "$") == 0) nr = tabpage_index(NULL) - 1; + else if (STRCMP(arg, "#") == 0) + nr = valid_tabpage(lastused_tabpage) ? + tabpage_index(lastused_tabpage) : 0; else semsg(_(e_invexpr2), arg); }