patch 8.2.4858: K_SPECIAL may be escaped twice
Problem: K_SPECIAL may be escaped twice.
Solution: Avoid double escaping. (closes #10340)
diff --git a/src/testdir/test_functions.vim b/src/testdir/test_functions.vim
index dbed757..a1b9b3d 100644
--- a/src/testdir/test_functions.vim
+++ b/src/testdir/test_functions.vim
@@ -2721,8 +2721,8 @@
call assert_equal('a', nr2char(97, 1))
call assert_equal('a', nr2char(97, 0))
- call assert_equal("\x80\xfc\b\xf4\x80\xfeX\x80\xfeX\x80\xfeX", eval('"\<M-' .. nr2char(0x100000) .. '>"'))
- call assert_equal("\x80\xfc\b\xfd\x80\xfeX\x80\xfeX\x80\xfeX\x80\xfeX\x80\xfeX", eval('"\<M-' .. nr2char(0x40000000) .. '>"'))
+ call assert_equal("\x80\xfc\b" .. nr2char(0x100000), eval('"\<M-' .. nr2char(0x100000) .. '>"'))
+ call assert_equal("\x80\xfc\b" .. nr2char(0x40000000), eval('"\<M-' .. nr2char(0x40000000) .. '>"'))
endfunc
" Test for screenattr(), screenchar() and screenchars() functions