0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.2.3969: value of MAXCOL not available in Vim script

Problem:    Value of MAXCOL not available in Vim script.
Solution:   Add v:maxcol. (Naohiro Ono, closes #9451)
This commit is contained in:
naohiro ono
2022-01-01 14:59:44 +00:00
committed by Bram Moolenaar
parent e70cec9760
commit 56200eed62
8 changed files with 40 additions and 15 deletions

View File

@@ -154,6 +154,7 @@ static struct vimvar
{VV_NAME("sizeofint", VAR_NUMBER), NULL, VV_RO},
{VV_NAME("sizeoflong", VAR_NUMBER), NULL, VV_RO},
{VV_NAME("sizeofpointer", VAR_NUMBER), NULL, VV_RO},
{VV_NAME("maxcol", VAR_NUMBER), NULL, VV_RO},
};
// shorthand
@@ -241,6 +242,7 @@ evalvars_init(void)
set_vim_var_nr(VV_SIZEOFINT, sizeof(int));
set_vim_var_nr(VV_SIZEOFLONG, sizeof(long));
set_vim_var_nr(VV_SIZEOFPOINTER, sizeof(char *));
set_vim_var_nr(VV_MAXCOL, MAXCOL);
set_vim_var_nr(VV_TYPE_NUMBER, VAR_TYPE_NUMBER);
set_vim_var_nr(VV_TYPE_STRING, VAR_TYPE_STRING);