mirror of
https://github.com/vim/vim.git
synced 2025-07-25 10:54:51 -04:00
patch 8.2.2183: Vim9: value of 'edcompatible' and 'gdefault' are used
Problem: Vim9: value of 'edcompatible' and 'gdefault' are used. Solution: Ignore these deprecated options in Vim9 script. (closes #7508)
This commit is contained in:
parent
f4e2099e39
commit
60f63100b9
@ -3778,6 +3778,15 @@ ex_substitute(exarg_T *eap)
|
|||||||
++cmd;
|
++cmd;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#ifdef FEAT_EVAL
|
||||||
|
if (in_vim9script())
|
||||||
|
{
|
||||||
|
// ignore 'gdefault' and 'edcompatible'
|
||||||
|
subflags.do_all = FALSE;
|
||||||
|
subflags.do_ask = FALSE;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
#endif
|
||||||
if (!p_ed)
|
if (!p_ed)
|
||||||
{
|
{
|
||||||
if (p_gd) // default is global on
|
if (p_gd) // default is global on
|
||||||
|
@ -740,4 +740,17 @@ def Test_magic_not_used()
|
|||||||
bwipe!
|
bwipe!
|
||||||
enddef
|
enddef
|
||||||
|
|
||||||
|
def Test_gdefault_not_used()
|
||||||
|
new
|
||||||
|
for cmd in ['set gdefault', 'set nogdefault']
|
||||||
|
exe cmd
|
||||||
|
setline(1, 'aaa')
|
||||||
|
s/./b/
|
||||||
|
assert_equal('baa', getline(1))
|
||||||
|
endfor
|
||||||
|
|
||||||
|
set nogdefault
|
||||||
|
bwipe!
|
||||||
|
enddef
|
||||||
|
|
||||||
" vim: ts=8 sw=2 sts=2 expandtab tw=80 fdm=marker
|
" vim: ts=8 sw=2 sts=2 expandtab tw=80 fdm=marker
|
||||||
|
@ -750,6 +750,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
2183,
|
||||||
/**/
|
/**/
|
||||||
2182,
|
2182,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user