patch 9.1.0469: Cannot have buffer-local value for 'completeopt'

Problem:  Cannot have buffer-local value for 'completeopt'
          (Nick Jensen).
Solution: Make 'completeopt' global-local (zeertzjq).

Also for some reason test Test_ColonEight_MultiByte seems to be failing
sporadically now. Let's mark it as flaky.

fixes: #5487
closes: #14922

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
zeertzjq
2024-06-05 20:27:06 +02:00
committed by Christian Brabandt
parent 84d9611b67
commit 529b9ad62a
14 changed files with 146 additions and 41 deletions

View File

@ -50,6 +50,7 @@
# define PV_CMS OPT_BUF(BV_CMS)
#endif
#define PV_COM OPT_BUF(BV_COM)
#define PV_COT OPT_BOTH(OPT_BUF(BV_COT))
#define PV_CPT OPT_BUF(BV_CPT)
#define PV_DICT OPT_BOTH(OPT_BUF(BV_DICT))
#define PV_TSR OPT_BOTH(OPT_BUF(BV_TSR))
@ -654,7 +655,7 @@ static struct vimoption options[] =
#endif
SCTX_INIT},
{"completeopt", "cot", P_STRING|P_VI_DEF|P_ONECOMMA|P_NODUP,
(char_u *)&p_cot, PV_NONE, did_set_completeopt, expand_set_completeopt,
(char_u *)&p_cot, PV_COT, did_set_completeopt, expand_set_completeopt,
{(char_u *)"menu,preview", (char_u *)0L}
SCTX_INIT},
{"completepopup", "cpp", P_STRING|P_VI_DEF|P_COMMA|P_NODUP|P_COLON,