[patch] doc fixes

2021-04-03 Fir de Conversatie Dominique Pellé
Hi

Attached patch fixes a few typos in vim-8.2.2706 doc.

Regards
Dominique

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/CAON-T_jeE%2BBitmKKigqCa3JvUeOd-qC5aC4s6qPg1aeVxyYAYw%40mail.gmail.com.
diff --git a/runtime/doc/usr_02.txt b/runtime/doc/usr_02.txt
index a866b7abb..53d6cb548 100644
--- a/runtime/doc/usr_02.txt
+++ b/runtime/doc/usr_02.txt
@@ -43,7 +43,7 @@ like:
 	|~	|
 	|"file.txt" [New file]			|
 	+---+
-		('#" is the cursor position.)
+		('#' is the cursor position.)
 
 The tilde (~) lines indicate lines not in the file.  In other words, when Vim
 runs out of file to display, it displays tilde lines.  At the bottom of the
diff --git a/runtime/doc/version5.txt b/runtime/doc/version5.txt
index 2b44cbda7..3a6e60efa 100644
--- a/runtime/doc/version5.txt
+++ b/runtime/doc/version5.txt
@@ -4403,7 +4403,7 @@ the last char of the line, "<<" moved an extra line.  Also for other operators
 that always work on lines.
 
 link.sh changed "-lnsl_s" to "_s" when looking for "nsl" to be removed.
-Now it only remove whole words.
+Now it only removes whole words.
 
 When jumped to a mark or using "fz", and there is an error, the current column
 was lost.  E.g. when using "$fzj".
diff --git a/runtime/doc/vim9.txt b/runtime/doc/vim9.txt
index 974ee6af6..cde97ff57 100644
--- a/runtime/doc/vim9.txt
+++ b/runtime/doc/vim9.txt
@@ -836,7 +836,7 @@ Patterns are used like 'magic' is set, unless explicitly overruled.
 The 'edcompatible' option value is not used.
 The 'gdefault' option value is not used.
 
-You may also find this wiki useful.  It was written by an early adoptor of
+You may also find this wiki useful.  It was written by an early adopter of
 Vim9 script: https://github.com/lacygoill/wiki/blob/master/vim/vim9.md
 
 ==
@@ -881,7 +881,7 @@ THIS IS STILL UNDER DEVELOPMENT - ANYTHING CAN BREAK - ANYTHING CAN CHANGE
 :enddef			End of a function defined with `:def`. It should be on
 			a line by its own.
 
-You may also find this wiki useful.  It was written by an early adoptor of
+You may also find this wiki useful.  It was written by an early adopter of
 Vim9 script: https://github.com/lacygoill/wiki/blob/master/vim/vim9.md
 
 If the script the function is defined in is Vim9 script, then script-local


Patch 8.2.2706

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2706
Problem:Vim9: wrong line number reported for boolean operator.
Solution:   Use the line number before skipping over line break.
(closes #8058)
Files:  src/vim9compile.c, src/testdir/test_vim9_expr.vim


*** ../vim-8.2.2705/src/vim9compile.c   2021-04-03 21:00:57.664184664 +0200
--- src/vim9compile.c   2021-04-03 21:34:42.222904826 +0200
***
*** 4772,4777 
--- 4772,4781 
ga_init2(_ga, sizeof(int), 10);
while (p[0] == opchar && p[1] == opchar)
{
+   longstart_lnum = SOURCING_LNUM;
+   int start_ctx_lnum = cctx->ctx_lnum;
+   int save_lnum;
+ 
if (next != NULL)
{
*arg = next_line_from_context(cctx, TRUE);
***
*** 4790,4800 
--- 4794,4809 
generate_ppconst(cctx, ppconst);
  
// Every part must evaluate to a bool.
+   SOURCING_LNUM = start_lnum;
+   save_lnum = cctx->ctx_lnum;
+   cctx->ctx_lnum = start_ctx_lnum;
if (bool_on_stack(cctx) == FAIL)
{
+   cctx->ctx_lnum = save_lnum;
ga_clear(_ga);
return FAIL;
}
+   cctx->ctx_lnum = save_lnum;
  
if (ga_grow(_ga, 1) == FAIL)
{
*** ../vim-8.2.2705/src/testdir/test_vim9_expr.vim  2021-03-22 
20:48:57.863992154 +0100
--- src/testdir/test_vim9_expr.vim  2021-04-03 21:38:31.922274939 +0200
***
*** 467,482 
CheckScriptFailure(lines, 'E1004:', 2)
  enddef
  
! func Test_expr3_fails()
!   let msg = "White space required before and after '&&'"
!   call CheckDefFailure(["var x = 1&&2"], msg, 1)
!   call CheckDefFailure(["var x = 1 &&2"], msg, 1)
!   call CheckDefFailure(["var x = 1&& 2"], msg, 1)
  
!   call CheckDefFailure(["if 'yes' && 0", 'echo 0', 'endif'], 'E1012: Type 
mismatch; expected bool but got string', 1)
  
!   call CheckDefExecFailure(['assert_equal(false, Record(1) && Record(4) && 
Record(0))'], 'E1023: Using a Number as a Bool: 4', 1)
! endfunc
  
  " global variables to use for tests with the "any" type
  let atrue = v:true
--- 467,496 
CheckScriptFailure(lines, 'E1004:', 2)
  enddef
  
! def Test_expr3_fails()
!   var msg = "White space required before and after '&&'"
!   CheckDefFailure(["var x = 1&&2"], msg, 1)
!   CheckDefFailure(["var x = 1 &&2"], msg, 1)
!   CheckDefFailure(["var x = 1&& 2"], msg, 1)
  
!   CheckDefFailure(["if 'yes' && 0", 'echo 0', 'endif'], 'E1012: Type 
mismatch; expected bool but got string', 1)
  
!   CheckDefExecFailure(['assert_equal(false, Record(1) && Record(4) && 
Record(0))'], 'E1023: Using a Number as a Bool: 4', 1)
! 
!   var lines =<< trim END
!   if 3
!   && true
!   endif
!   END
!   CheckDefExecFailure(lines, 'E1023:', 1)
! 
!   lines =<< trim END
!   if 'yes'
!   && true
!   endif
!   END
!   CheckDefFailure(lines, 'E1012:', 1)
! enddef
  
  " global variables to use for tests with the "any" type
  let atrue = v:true
*** ../vim-8.2.2705/src/version.c   2021-04-03 21:00:57.668184656 +0200
--- src/version.c   2021-04-03 21:44:45.797272681 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2706,
  /**/

-- 
"I can't complain, but sometimes I still do."   (Joe Walsh)

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031947.133Jlkh62612285%40masaka.moolenaar.net.


Patch 8.2.2705

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2705
Problem:Vim9: misleading reported line number for wrong type.
Solution:   Remember and use the line number at the start. (closes #8059)
Files:  src/vim9compile.c, src/testdir/test_vim9_assign.vim


*** ../vim-8.2.2704/src/vim9compile.c   2021-04-01 21:38:46.753298941 +0200
--- src/vim9compile.c   2021-04-03 20:57:18.436618058 +0200
***
*** 6166,6171 
--- 6166,6172 
  char_u*sp;
  int   is_decl = is_decl_command(cmdidx);
  lhs_T lhs;
+ long  start_lnum = SOURCING_LNUM;
  
  // Skip over the "var" or "[var, var]" to get to any "=".
  p = skip_var_list(arg, TRUE, _count, , TRUE);
***
*** 6393,6399 
{
type_T *use_type = lhs.lhs_lvar->lv_type;
  
!   // without operator check type here, otherwise below
if (lhs.lhs_has_index)
use_type = lhs.lhs_member_type;
if (need_type(rhs_type, use_type, -1, 0, cctx,
--- 6394,6402 
{
type_T *use_type = lhs.lhs_lvar->lv_type;
  
!   // Without operator check type here, otherwise below.
!   // Use the line number of the assignment.
!   SOURCING_LNUM = start_lnum;
if (lhs.lhs_has_index)
use_type = lhs.lhs_member_type;
if (need_type(rhs_type, use_type, -1, 0, cctx,
*** ../vim-8.2.2704/src/testdir/test_vim9_assign.vim2021-04-03 
19:32:40.750286283 +0200
--- src/testdir/test_vim9_assign.vim2021-04-03 20:56:59.008653929 +0200
***
*** 315,320 
--- 315,328 
assert_equal(34, n2)
  
CheckDefFailure(["var x = #"], 'E1097:', 3)
+ 
+   var lines =<< trim END
+   var x: list = ['a']
+   var y: list = x
+   ->copy()
+   ->copy()
+   END
+   CheckDefFailure(lines, 'E1012:', 2)
  enddef
  
  def Test_assign_index()
*** ../vim-8.2.2704/src/version.c   2021-04-03 20:13:25.594782463 +0200
--- src/version.c   2021-04-03 20:55:11.348843204 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2705,
  /**/

-- 
Master: Boy, there is nothing more for you to learn
Student: I didn't know that!

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031901.133J1YpI2603106%40masaka.moolenaar.net.


Re: Patch 8.2.2699

2021-04-03 Fir de Conversatie Bram Moolenaar


Yegappan wrote:

> On Sat, Apr 3, 2021 at 8:19 AM Bram Moolenaar  wrote:
> >
> >
> > Patch 8.2.2699
> > Problem:Lua test fails.
> > Solution:   Fix condition. (Yegappan Lakshmanan, closes #8060)
> > Files:  src/testdir/test_lua.vim
> >
> >
> 
> There are still two test failures (not related to lua).
> 
> A memory leak is detected by leak sanitizer:
> 
> #1 0x9a6a87 in lalloc /home/runner/work/vim/vim/src/misc2.c:925:11
> 32 #2 0x9a6a5d in alloc /home/runner/work/vim/vim/src/misc2.c:828:12
> 33 #3 0x9a7638 in vim_strsave /home/runner/work/vim/vim/src/misc2.c:1281:9
> 34 #4 0xf097b3 in call_def_function
> /home/runner/work/vim/vim/src/vim9execute.c:2461:24
> 35 #5 0xe797c0 in call_user_func 
> /home/runner/work/vim/vim/src/userfunc.c:2204:2
> 36 #6 0xe76dbc in call_user_func_check
> /home/runner/work/vim/vim/src/userfunc.c:2592:2
> 37 #7 0xe73144 in call_func /home/runner/work/vim/vim/src/userfunc.c:3070:11
> 38 #8 0xe71e25 in get_func_tv /home/runner/work/vim/vim/src/userfunc.c:1469:8
> 39 #9 0xe93e82 in ex_call /home/runner/work/vim/vim/src/userfunc.c:4710:6

Yes, caused by the new check for a locked script varialbe.  Fixed by
8.2.2703.

> Another test failure in test_terminal.vim:
> 
> >From test_terminal.vim:
> 11818 Found errors in Test_terminal_nested_autocmd():
> 11819 Run 1:
> 11820 Caught exception in Test_terminal_nested_autocmd():
> Vim(bwipeout):E89: No write since last change for buffer 54 (add ! to
> override) @ command line..script
> D:/a/vim/vim/src2/testdir/runtest.vim[473]..function
> RunTheTest[44]..Test_terminal_nested_autocmd, line 16

Depending on the system the external command may finish sooner or later.
More reliable way to handle that in 8.2.2700.

-- 
hundred-and-one symptoms of being an internet addict:
52. You ask a plumber how much it would cost to replace the chair in front of
your computer with a toilet.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031813.133IDtHn2592334%40masaka.moolenaar.net.


Patch 8.2.2704

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2704
Problem:Adding a lot of completions can be a bit slow.
Solution:   Use fast_breakcheck() instead of ui_breakcheck() when adding a
list of completions. (Ben Jackson, closes #8061)
Files:  src/insexpand.c


*** ../vim-8.2.2703/src/insexpand.c 2021-01-29 21:47:20.485738910 +0100
--- src/insexpand.c 2021-04-03 20:11:22.095127230 +0200
***
*** 118,123 
--- 118,124 
  # define CP_CONT_S_IPOS   4   // use CONT_S_IPOS for compl_cont_status
  # define CP_EQUAL 8   // ins_compl_equal() always returns TRUE
  # define CP_ICASE 16  // ins_compl_equal() ignores case
+ # define CP_FAST  32  // use fast_breakcheck instead of ui_breakcheck
  
  static char e_hitend[] = N_("Hit end of paragraph");
  # ifdef FEAT_COMPL_FUNC
***
*** 790,796 
  
  for (i = 0; i < num_matches && add_r != FAIL; i++)
if ((add_r = ins_compl_add(matches[i], -1, NULL, NULL, NULL, dir,
!  icase ? CP_ICASE : 0, FALSE)) == OK)
// if dir was BACKWARD then honor it just once
dir = FORWARD;
  FreeWild(num_matches, matches);
--- 791,797 
  
  for (i = 0; i < num_matches && add_r != FAIL; i++)
if ((add_r = ins_compl_add(matches[i], -1, NULL, NULL, NULL, dir,
!  CP_FAST | (icase ? CP_ICASE : 0), FALSE)) == OK)
// if dir was BACKWARD then honor it just once
dir = FORWARD;
  FreeWild(num_matches, matches);
***
*** 1567,1573 
  // Respect the 'backspace' option.
  if ((int)(p - line) - (int)compl_col < 0
|| ((int)(p - line) - (int)compl_col == 0
!   && ctrl_x_mode != CTRL_X_OMNI) || ctrl_x_mode == CTRL_X_EVAL
|| (!can_bs(BS_START) && (int)(p - line) - (int)compl_col
- compl_length < 0))
return K_BS;
--- 1568,1575 
  // Respect the 'backspace' option.
  if ((int)(p - line) - (int)compl_col < 0
|| ((int)(p - line) - (int)compl_col == 0
!&& ctrl_x_mode != CTRL_X_OMNI)
!   || ctrl_x_mode == CTRL_X_EVAL
|| (!can_bs(BS_START) && (int)(p - line) - (int)compl_col
- compl_length < 0))
return K_BS;
***
*** 2271,2284 
   * If the given string is already in the list of completions, then return
   * NOTDONE, otherwise add it to the list and return OK.  If there is an error,
   * maybe because alloc() returns NULL, then FAIL is returned.
   */
  static int
! ins_compl_add_tv(typval_T *tv, int dir)
  {
  char_u*word;
  int   dup = FALSE;
  int   empty = FALSE;
! int   flags = 0;
  char_u*(cptext[CPT_COUNT]);
  typval_T  user_data;
  
--- 2273,2287 
   * If the given string is already in the list of completions, then return
   * NOTDONE, otherwise add it to the list and return OK.  If there is an error,
   * maybe because alloc() returns NULL, then FAIL is returned.
+  * When "fast" is TRUE use fast_breakcheck() instead of ui_breakcheck().
   */
  static int
! ins_compl_add_tv(typval_T *tv, int dir, int fast)
  {
  char_u*word;
  int   dup = FALSE;
  int   empty = FALSE;
! int   flags = fast ? CP_FAST : 0;
  char_u*(cptext[CPT_COUNT]);
  typval_T  user_data;
  
***
*** 2329,2335 
  CHECK_LIST_MATERIALIZE(list);
  FOR_ALL_LIST_ITEMS(list, li)
  {
!   if (ins_compl_add_tv(>li_tv, dir) == OK)
// if dir was BACKWARD then honor it just once
dir = FORWARD;
else if (did_emsg)
--- 2332,2338 
  CHECK_LIST_MATERIALIZE(list);
  FOR_ALL_LIST_ITEMS(list, li)
  {
!   if (ins_compl_add_tv(>li_tv, dir, TRUE) == OK)
// if dir was BACKWARD then honor it just once
dir = FORWARD;
else if (did_emsg)
***
*** 2391,2397 
  if (p_ic)
flags |= CP_ICASE;
  if (compl_orig_text == NULL || ins_compl_add(compl_orig_text,
! -1, NULL, NULL, NULL, 0, flags, FALSE) != OK)
return;
  
  ctrl_x_mode = CTRL_X_EVAL;
--- 2394,2401 
  if (p_ic)
flags |= CP_ICASE;
  if (compl_orig_text == NULL || ins_compl_add(compl_orig_text,
! -1, NULL, NULL, NULL, 0,
! flags | CP_FAST, FALSE) != OK)
return;
  
  ctrl_x_mode = CTRL_X_EVAL;
***
*** 2461,2467 
  void
  f_complete_add(typval_T *argvars, typval_T *rettv)
  {
! rettv->vval.v_number = ins_compl_add_tv([0], 0);
  }
  
  /*
--- 2465,2471 
  void
  f_complete_add(typval_T *argvars, typval_T *rettv)
  {
! rettv->vval.v_number = 

Patch 8.2.2703

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2703
Problem:Vim9: memory leak when failing on locked variable.
Solution:   Free the memory.
Files:  src/vim9execute.c, src/testdir/test_vim9_assign.vim


*** ../vim-8.2.2702/src/vim9execute.c   2021-04-02 14:43:52.947178932 +0200
--- src/vim9execute.c   2021-04-03 19:28:48.622897008 +0200
***
*** 1944,1950 
--- 1944,1953 
{
SOURCING_LNUM = iptr->isn_lnum;
if (var_check_permission(di, name) == FAIL)
+   {
+   clear_tv(STACK_TV_BOT(0));
goto on_error;
+   }
clear_tv(>di_tv);
di->di_tv = *STACK_TV_BOT(0);
}
***
*** 1966,1972 
--- 1969,1978 
// the value needs to be checked here.
SOURCING_LNUM = iptr->isn_lnum;
if (value_check_lock(sv->sv_tv->v_lock, sv->sv_name, FALSE))
+   {
+   clear_tv(STACK_TV_BOT(0));
goto on_error;
+   }
  
clear_tv(sv->sv_tv);
*sv->sv_tv = *STACK_TV_BOT(0);
*** ../vim-8.2.2702/src/testdir/test_vim9_assign.vim2021-04-02 
14:43:52.947178932 +0200
--- src/testdir/test_vim9_assign.vim2021-04-03 19:29:25.494800320 +0200
***
*** 1323,1328 
--- 1323,1329 
unlet g:var_test
unlet g:var_prefixed
unlet g:other_var
+   unlet g:globConst
unlet g:FOO
unlet g:FOOS
unlet g:FLIST
***
*** 1375,1381 
  SetGlobalConst()
  g:globConst = 234
END
!   CheckScriptFailure(lines, 'E741: Value is locked: globConst', 1)
unlet g:globConst
  
lines =<< trim END
--- 1376,1382 
  SetGlobalConst()
  g:globConst = 234
END
!   CheckScriptFailure(lines, 'E741: Value is locked: g:globConst', 6)
unlet g:globConst
  
lines =<< trim END
*** ../vim-8.2.2702/src/version.c   2021-04-03 19:07:02.106066631 +0200
--- src/version.c   2021-04-03 19:32:26.174324758 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2703,
  /**/

-- 
Never go to the toilet in a paperless office.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031733.133HX99q2582434%40masaka.moolenaar.net.


Patch 8.2.2702

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2702
Problem:Compiler completion test fails when more scripts are added.
Solution:   Add a more generic pattern.
Files:  src/testdir/test_compiler.vim


*** ../vim-8.2.2701/src/testdir/test_compiler.vim   2020-11-27 
19:13:24.186184976 +0100
--- src/testdir/test_compiler.vim   2021-04-03 19:05:25.294252451 +0200
***
*** 69,78 
call assert_match('^"compiler ' .. clist .. '$', @:)
  
call feedkeys(":compiler p\\\"\", 'tx')
!   call assert_equal('"compiler pbx perl php pylint pyunit', @:)
  
call feedkeys(":compiler! p\\\"\", 'tx')
!   call assert_equal('"compiler! pbx perl php pylint pyunit', @:)
  endfunc
  
  func Test_compiler_error()
--- 69,78 
call assert_match('^"compiler ' .. clist .. '$', @:)
  
call feedkeys(":compiler p\\\"\", 'tx')
!   call assert_match('"compiler pbx perl\( p[a-z]\+\)\+ pylint pyunit', @:)
  
call feedkeys(":compiler! p\\\"\", 'tx')
!   call assert_match('"compiler! pbx perl\( p[a-z]\+\)\+ pylint pyunit', @:)
  endfunc
  
  func Test_compiler_error()
*** ../vim-8.2.2701/src/version.c   2021-04-03 17:33:49.173081862 +0200
--- src/version.c   2021-04-03 19:06:22.802143705 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2702,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
51. You put a pillow case over your laptop so your lover doesn't see it while
you are pretending to catch your breath.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031712.133HCquo2577701%40masaka.moolenaar.net.


Patch 8.2.2701

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2701
Problem:Order of removing FORTIFY_SOURCE is wrong.
Solution:   Use the more specific pattern first.
Files:  src/configure.ac, src/auto/configure


*** ../vim-8.2.2700/src/configure.ac2021-04-02 13:30:56.350856326 +0200
--- src/configure.ac2021-04-03 17:31:04.045757931 +0200
***
*** 4484,4491 
dnl And undefine it first to avoid a warning.
AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1)
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 
's/,-D_FORTIFY_SOURCE=. //g' -e 's/ *-Wp,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g' -e 's/$/ 
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'`
! CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 
's/,-D_FORTIFY_SOURCE=. //g' -e 's/ *-Wp,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g'`
  AC_MSG_RESULT(yes)
else
  AC_MSG_RESULT(no)
--- 4484,4491 
dnl And undefine it first to avoid a warning.
AC_MSG_CHECKING(whether we need -D_FORTIFY_SOURCE=1)
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 's/ 
*-Wp,-D_FORTIFY_SOURCE=. / /g' -e 's/,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g' -e 's/$/ 
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'`
! CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 's/ 
*-Wp,-D_FORTIFY_SOURCE=. / /g' -e 's/,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g'`
  AC_MSG_RESULT(yes)
else
  AC_MSG_RESULT(no)
*** ../vim-8.2.2700/src/auto/configure  2021-04-02 13:30:56.350856326 +0200
--- src/auto/configure  2021-04-03 17:32:25.565419826 +0200
***
*** 14906,14913 
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need 
-D_FORTIFY_SOURCE=1" >&5
  $as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; }
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 
's/,-D_FORTIFY_SOURCE=. //g' -e 's/ *-Wp,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g' -e 's/$/ 
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'`
! CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 
's/,-D_FORTIFY_SOURCE=. //g' -e 's/ *-Wp,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g'`
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  $as_echo "yes" >&6; }
else
--- 14906,14913 
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we need 
-D_FORTIFY_SOURCE=1" >&5
  $as_echo_n "checking whether we need -D_FORTIFY_SOURCE=1... " >&6; }
if test "$gccmajor" -gt "3"; then
! CFLAGS=`echo "$CFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 's/ 
*-Wp,-D_FORTIFY_SOURCE=. / /g' -e 's/,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g' -e 's/$/ 
-U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1/'`
! CPPFLAGS=`echo "$CPPFLAGS" | sed -e 's/-D_FORTIFY_SOURCE=.,//g' -e 's/ 
*-Wp,-D_FORTIFY_SOURCE=. / /g' -e 's/,-D_FORTIFY_SOURCE=. //g' -e 's/ 
*-D_FORTIFY_SOURCE=.//g' -e 's/ *-U_FORTIFY_SOURCE//g'`
  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
  $as_echo "yes" >&6; }
else
*** ../vim-8.2.2700/src/version.c   2021-04-03 17:22:24.752228600 +0200
--- src/version.c   2021-04-03 17:32:47.177331662 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2701,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
50. The last girl you picked up was only a jpeg.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031534.133FYHXD2548802%40masaka.moolenaar.net.


Re: Patch 8.2.2699

2021-04-03 Fir de Conversatie Yegappan Lakshmanan
Hi Bram,

On Sat, Apr 3, 2021 at 8:19 AM Bram Moolenaar  wrote:
>
>
> Patch 8.2.2699
> Problem:Lua test fails.
> Solution:   Fix condition. (Yegappan Lakshmanan, closes #8060)
> Files:  src/testdir/test_lua.vim
>
>

There are still two test failures (not related to lua).

A memory leak is detected by leak sanitizer:

#1 0x9a6a87 in lalloc /home/runner/work/vim/vim/src/misc2.c:925:11
32 #2 0x9a6a5d in alloc /home/runner/work/vim/vim/src/misc2.c:828:12
33 #3 0x9a7638 in vim_strsave /home/runner/work/vim/vim/src/misc2.c:1281:9
34 #4 0xf097b3 in call_def_function
/home/runner/work/vim/vim/src/vim9execute.c:2461:24
35 #5 0xe797c0 in call_user_func /home/runner/work/vim/vim/src/userfunc.c:2204:2
36 #6 0xe76dbc in call_user_func_check
/home/runner/work/vim/vim/src/userfunc.c:2592:2
37 #7 0xe73144 in call_func /home/runner/work/vim/vim/src/userfunc.c:3070:11
38 #8 0xe71e25 in get_func_tv /home/runner/work/vim/vim/src/userfunc.c:1469:8
39 #9 0xe93e82 in ex_call /home/runner/work/vim/vim/src/userfunc.c:4710:6

Another test failure in test_terminal.vim:

>From test_terminal.vim:
11818 Found errors in Test_terminal_nested_autocmd():
11819 Run 1:
11820 Caught exception in Test_terminal_nested_autocmd():
Vim(bwipeout):E89: No write since last change for buffer 54 (add ! to
override) @ command line..script
D:/a/vim/vim/src2/testdir/runtest.vim[473]..function
RunTheTest[44]..Test_terminal_nested_autocmd, line 16


- Yegappan

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/CAAW7x7%3DrzQMkmb-Q9j91BrXkJ%2BhLVh7%3D3u4DUKas%3DjCQGZzSBQ%40mail.gmail.com.


Patch 8.2.2700

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2700
Problem:Nested autocmd test fails sometimes.
Solution:   Wait for the job to finish.
Files:  src/testdir/test_terminal.vim


*** ../vim-8.2.2699/src/testdir/test_terminal.vim   2021-04-03 
13:19:23.106814487 +0200
--- src/testdir/test_terminal.vim   2021-04-03 17:16:00.525485767 +0200
***
*** 2021,2028 
let buf = term_start(cmd, #{term_finish: 'close', hidden: 1})
call assert_equal(lastline, line('.'))
  
!   call TermWait(buf)
!   exe buf . 'bwipe'
call delete('Xtext')
augroup TermTest
  au!
--- 2021,2028 
let buf = term_start(cmd, #{term_finish: 'close', hidden: 1})
call assert_equal(lastline, line('.'))
  
!   let job = term_getjob(buf)
!   call WaitForAssert({-> assert_equal("dead", job_status(job))})
call delete('Xtext')
augroup TermTest
  au!
*** ../vim-8.2.2699/src/version.c   2021-04-03 17:18:47.296936719 +0200
--- src/version.c   2021-04-03 17:20:25.564615758 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2700,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
49. You never have to deal with busy signals when calling your ISP...because
you never log off.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031523.133FNNu42546391%40masaka.moolenaar.net.


Patch 8.2.2699

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2699
Problem:Lua test fails.
Solution:   Fix condition. (Yegappan Lakshmanan, closes #8060)
Files:  src/testdir/test_lua.vim


*** ../vim-8.2.2698/src/testdir/test_lua.vim2021-04-03 15:35:43.217048704 
+0200
--- src/testdir/test_lua.vim2021-04-03 17:11:40.498357804 +0200
***
*** 20,26 
  endif
  let s:major = str2nr(s:luaver[0])
  let s:minor = str2nr(s:luaver[1])
! if len(s:luaver >= 3)
let s:patch = str2nr(s:luaver[2])
  else
let s:patch = 0
--- 20,26 
  endif
  let s:major = str2nr(s:luaver[0])
  let s:minor = str2nr(s:luaver[1])
! if len(s:luaver) >= 3
let s:patch = str2nr(s:luaver[2])
  else
let s:patch = 0
*** ../vim-8.2.2698/src/version.c   2021-04-03 15:35:43.221048697 +0200
--- src/version.c   2021-04-03 17:18:31.396988805 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2699,
  /**/

-- 
There is a difference between "should work" and "does work",
it's called testing.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031519.133FJN262545454%40masaka.moolenaar.net.


Re: Patch 8.2.2698

2021-04-03 Fir de Conversatie Bram Moolenaar


> > > Patch 8.2.2698 (after 8.2.2696)
> > > Problem:Lua test fails on MS-Windows.
> > > Solution:   Fall back to old method if "lua -v" doesn't work.
> > > Files:  src/testdir/test_lua.vim
> >
> > This probably still fails with the "lua" command has a different version
> > than the library that Vim was built with.  I hope someone can figure
> > out a better solution to get the patch level.
> >
> 
> Yes. The Lua _VERSION global variable only contains the major and
> minor version numbers. It doesn't have the patch version number.
> When the lua command is invoked with the "-v" argument, then it
> displays all the three version numbers. But if the lua executable is
> not present in the PATH or some other version is found, then we may
> get the wrong Lua version. I hope someone more familiar with Lua
> can chime in with a solution to get the Lua version.

I suspect that the executable may be called something else, e.g.
"lua45".

-- 
hundred-and-one symptoms of being an internet addict:
48. You get a tatoo that says "This body best viewed with Netscape 3.1 or
higher."

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031519.133FJM062545448%40masaka.moolenaar.net.


Re: Patch 8.2.2698

2021-04-03 Fir de Conversatie Yegappan Lakshmanan
Hi Bram,

On Sat, Apr 3, 2021 at 6:38 AM Bram Moolenaar  wrote:
>
>
> I wrote:
>
> > Patch 8.2.2698 (after 8.2.2696)
> > Problem:Lua test fails on MS-Windows.
> > Solution:   Fall back to old method if "lua -v" doesn't work.
> > Files:  src/testdir/test_lua.vim
>
> This probably still fails with the "lua" command has a different version
> than the library that Vim was built with.  I hope someone can figure
> out a better solution to get the patch level.
>

Yes. The Lua _VERSION global variable only contains the major and
minor version numbers. It doesn't have the patch version number.
When the lua command is invoked with the "-v" argument, then it
displays all the three version numbers. But if the lua executable is
not present in the PATH or some other version is found, then we may
get the wrong Lua version. I hope someone more familiar with Lua
can chime in with a solution to get the Lua version.

https://www.lua.org/manual/5.3/manual.html#pdf-_VERSION
https://stackoverflow.com/questions/18268528/is-it-possible-to-get-lua-interpreter-version-information-in-script

Regards,
Yegappan

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/CAAW7x7nporNobrpkZZbBNV6w01hv0apCUM-iz4MHnC%2BrGx9qtQ%40mail.gmail.com.


Re: Patch 8.2.2698

2021-04-03 Fir de Conversatie Bram Moolenaar


I wrote:

> Patch 8.2.2698 (after 8.2.2696)
> Problem:Lua test fails on MS-Windows.
> Solution:   Fall back to old method if "lua -v" doesn't work.
> Files:  src/testdir/test_lua.vim

This probably still fails with the "lua" command has a different version
than the library that Vim was built with.  I hope someone can figure
out a better solution to get the patch level.

-- 
The real
trick is
this: to
keep the
lines as
short as
possible
and keep
the size
the same
yet free
from the
need for
hyphena-
Dammit!!  (Matthew Winn)

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031338.133Dca3e2524849%40masaka.moolenaar.net.


Patch 8.2.2698

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2698 (after 8.2.2696)
Problem:Lua test fails on MS-Windows.
Solution:   Fall back to old method if "lua -v" doesn't work.
Files:  src/testdir/test_lua.vim


*** ../vim-8.2.2697/src/testdir/test_lua.vim2021-04-03 14:13:29.644785091 
+0200
--- src/testdir/test_lua.vim2021-04-03 15:33:31.101356508 +0200
***
*** 14,22 
  
  " Depending on the lua version, the error messages are different.
  let s:luaver = split(split(systemlist('lua -v')[0], ' ')[1], '\.')
  let s:major = str2nr(s:luaver[0])
  let s:minor = str2nr(s:luaver[1])
! let s:patch = str2nr(s:luaver[2])
  let s:lua_53_or_later = 0
  let s:lua_543_or_later = 0
  if (s:major == 5 && s:minor >= 3) || s:major > 5
--- 14,30 
  
  " Depending on the lua version, the error messages are different.
  let s:luaver = split(split(systemlist('lua -v')[0], ' ')[1], '\.')
+ if len(s:luaver) < 3
+   " Didn't get something that looks like a version, use _VERSION.
+   let s:luaver = split(split(luaeval('_VERSION'), ' ')[1], '\.')
+ endif
  let s:major = str2nr(s:luaver[0])
  let s:minor = str2nr(s:luaver[1])
! if len(s:luaver >= 3)
!   let s:patch = str2nr(s:luaver[2])
! else
!   let s:patch = 0
! endif
  let s:lua_53_or_later = 0
  let s:lua_543_or_later = 0
  if (s:major == 5 && s:minor >= 3) || s:major > 5
*** ../vim-8.2.2697/src/version.c   2021-04-03 15:15:43.871614324 +0200
--- src/version.c   2021-04-03 15:35:13.897117232 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2698,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
47. You are so familiar with the WWW that you find the search engines useless.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031336.133DaLXv2524242%40masaka.moolenaar.net.


Patch 8.2.2697

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2697
Problem:Function list test fails.
Solution:   Add missing function. (Yegappan Lakshmanan)
Files:  runtime/doc/usr_41.txt


*** ../vim-8.2.2696/runtime/doc/usr_41.txt  2021-03-14 19:01:34.492421821 
+0100
--- runtime/doc/usr_41.txt  2021-04-03 14:08:42.225650912 +0200
***
*** 1003,1008 
--- 1003,1009 
assert_true()   assert that an expression is true
assert_exception()  assert that a command throws an exception
assert_beeps()  assert that a command beeps
+   assert_nobeep() assert that a command does not cause a beep
assert_fails()  assert that a command fails
assert_report() report a test failure
test_alloc_fail()   make memory allocation fail
*** ../vim-8.2.2696/src/version.c   2021-04-03 14:13:29.644785091 +0200
--- src/version.c   2021-04-03 15:15:26.331644217 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2697,
  /**/

-- 
hundred-and-one symptoms of being an internet addict:
43. You tell the kids they can't use the computer because "Daddy's got work to
do" and you don't even have a job.

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031317.133DHfca2516166%40masaka.moolenaar.net.


Re: syntax/vim.vim - support python << trim

2021-04-03 Fir de Conversatie Ben Jackson
Hi Charles,
> 
> Vim 8.1 has supported py3 < to the runtime file for syntax/vim.vim
> 
> Would you consider including it?
> 
> <0001-Runtime-vim-python-syntax-supports-trim.patch>
> 
> THanks,
> Ben

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/2D73FFA4-B339-41B8-B52E-3E65726BAFC0%40gmail.com.


0001-Runtime-vim-python-syntax-supports-trim.patch
Description: Binary data


syntax/vim.vim - support python << trim

2021-04-03 Fir de Conversatie Ben Jackson
Hi Charles,

Vim 8.1 has supported py3 

Patch 8.2.2696

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2696
Problem:Lua test fails with Lua 5.4.3 and later.
Solution:   Check for different error messages. (Yegappan Lakshmanan,
closes #8050)
Files:  src/testdir/test_lua.vim


*** ../vim-8.2.2695/src/testdir/test_lua.vim2021-03-08 19:50:20.452224854 
+0100
--- src/testdir/test_lua.vim2021-04-03 14:08:42.225650912 +0200
***
*** 12,24 
  CheckFeature lua
  CheckFeature float
  
! let s:luaver = split(split(luaeval('_VERSION'), ' ')[1], '\.')
  let s:major = str2nr(s:luaver[0])
  let s:minor = str2nr(s:luaver[1])
! if s:major < 5 || (s:major == 5 && s:minor < 3)
!   let s:lua_53_or_later = 0
! else
let s:lua_53_or_later = 1
  endif
  
  func TearDown()
--- 12,31 
  CheckFeature lua
  CheckFeature float
  
! " Depending on the lua version, the error messages are different.
! let s:luaver = split(split(systemlist('lua -v')[0], ' ')[1], '\.')
  let s:major = str2nr(s:luaver[0])
  let s:minor = str2nr(s:luaver[1])
! let s:patch = str2nr(s:luaver[2])
! let s:lua_53_or_later = 0
! let s:lua_543_or_later = 0
! if (s:major == 5 && s:minor >= 3) || s:major > 5
let s:lua_53_or_later = 1
+   if (s:major == 5
+ \ && ((s:minor == 4 && s:patch >= 3) || s:minor > 4))
+ \ || s:major > 5
+ let s:lua_543_or_later = 1
+   endif
  endif
  
  func TearDown()
***
*** 55,64 
" Error cases
call assert_fails('luado string.format()',
  \ "[string \"vim chunk\"]:1: bad argument #1 to 'format' (string 
expected, got no value)")
!   call assert_fails('luado func()',
! \ s:lua_53_or_later
! \ ? "[string \"vim chunk\"]:1: attempt to call a nil value (global 
'func')"
! \ : "[string \"vim chunk\"]:1: attempt to call global 'func' (a nil 
value)")
call assert_fails('luado error("failed")', "[string \"vim chunk\"]:1: 
failed")
  endfunc
  
--- 62,75 
" Error cases
call assert_fails('luado string.format()',
  \ "[string \"vim chunk\"]:1: bad argument #1 to 'format' (string 
expected, got no value)")
!   if s:lua_543_or_later
! let msg = "[string \"vim chunk\"]:1: global 'func' is not callable (a nil 
value)"
!   elseif s:lua_53_or_later
! let msg = "[string \"vim chunk\"]:1: attempt to call a nil value (global 
'func')"
!   else
! let msg = "[string \"vim chunk\"]:1: attempt to call global 'func' (a nil 
value)"
!   endif
!   call assert_fails('luado func()', msg)
call assert_fails('luado error("failed")', "[string \"vim chunk\"]:1: 
failed")
  endfunc
  
***
*** 143,152 
" Window 3 does not exist so vim.window(3) should return nil
call assert_equal('nil', luaeval('tostring(vim.window(3))'))
  
!   call assert_fails("let n = luaeval('vim.window().xyz()')",
! \ s:lua_53_or_later
! \ ? "[string \"luaeval\"]:1: attempt to call a nil value (field 
'xyz')"
! \ : "[string \"luaeval\"]:1: attempt to call field 'xyz' (a nil 
value)")
call assert_fails('lua vim.window().xyz = 1',
  \ "[string \"vim chunk\"]:1: invalid window property: `xyz'")
  
--- 154,167 
" Window 3 does not exist so vim.window(3) should return nil
call assert_equal('nil', luaeval('tostring(vim.window(3))'))
  
!   if s:lua_543_or_later
! let msg = "[string \"luaeval\"]:1: field 'xyz' is not callable (a nil 
value)"
!   elseif s:lua_53_or_later
! let msg = "[string \"luaeval\"]:1: attempt to call a nil value (field 
'xyz')"
!   else
! let msg = "[string \"luaeval\"]:1: attempt to call field 'xyz' (a nil 
value)"
!   endif
!   call assert_fails("let n = luaeval('vim.window().xyz()')", msg)
call assert_fails('lua vim.window().xyz = 1',
  \ "[string \"vim chunk\"]:1: invalid window property: `xyz'")
  
***
*** 331,340 
call assert_equal('4', luaeval('vim.buffer()[4]'))
call assert_equal(v:null, luaeval('vim.buffer()[5]'))
call assert_equal(v:null, luaeval('vim.buffer()[{}]'))
!   call assert_fails('lua vim.buffer():xyz()',
! \ s:lua_53_or_later
! \ ? "[string \"vim chunk\"]:1: attempt to call a nil value (method 
'xyz')"
! \ : "[string \"vim chunk\"]:1: attempt to call method 'xyz' (a nil 
value)")
call assert_fails('lua vim.buffer()[1] = {}',
  \ '[string "vim chunk"]:1: wrong argument to change')
bwipe!
--- 346,359 
call assert_equal('4', luaeval('vim.buffer()[4]'))
call assert_equal(v:null, luaeval('vim.buffer()[5]'))
call assert_equal(v:null, luaeval('vim.buffer()[{}]'))
!   if s:lua_543_or_later
! let msg = "[string \"vim chunk\"]:1: method 'xyz' is not callable (a nil 
value)"
!   elseif s:lua_53_or_later
! let msg = "[string \"vim chunk\"]:1: attempt to call a nil value (method 
'xyz')"
!   else
! let msg = "[string \"vim chunk\"]:1: attempt to call method 'xyz' (a nil 
value)"
!   endif
!   call assert_fails('lua vim.buffer():xyz()', msg)
call assert_fails('lua vim.buffer()[1] = {}',
  \ '[string 

Patch 8.2.2695

2021-04-03 Fir de Conversatie Bram Moolenaar


Patch 8.2.2695
Problem:Cursor position reset with nested autocommands.
Solution:   Only check and reset line numbers for not nested autocommands.
(closes #5820)
Files:  src/autocmd.c, src/testdir/test_terminal.vim


*** ../vim-8.2.2694/src/autocmd.c   2021-03-13 15:47:51.573753561 +0100
--- src/autocmd.c   2021-04-03 13:18:38.546931429 +0200
***
*** 2116,2129 
ap->last = FALSE;
ap->last = TRUE;
  
!   // make sure cursor and topline are valid
!   check_lnums(TRUE);
  
do_cmdline(NULL, getnextac, (void *),
 DOCMD_NOWAIT|DOCMD_VERBOSE|DOCMD_REPEAT);
  
!   // restore cursor and topline, unless they were changed
!   reset_lnums();
  
  #ifdef FEAT_EVAL
if (eap != NULL)
--- 2116,2131 
ap->last = FALSE;
ap->last = TRUE;
  
!   if (nesting == 1)
!   // make sure cursor and topline are valid
!   check_lnums(TRUE);
  
do_cmdline(NULL, getnextac, (void *),
 DOCMD_NOWAIT|DOCMD_VERBOSE|DOCMD_REPEAT);
  
!   if (nesting == 1)
!   // restore cursor and topline, unless they were changed
!   reset_lnums();
  
  #ifdef FEAT_EVAL
if (eap != NULL)
*** ../vim-8.2.2694/src/testdir/test_terminal.vim   2021-03-23 
16:25:05.910822743 +0100
--- src/testdir/test_terminal.vim   2021-04-03 13:17:35.003097520 +0200
***
*** 2002,2006 
--- 2002,2033 
call delete('Xcolorscript')
  endfunc
  
+ function On_BufFilePost()
+ doautocmd  User UserEvent
+ endfunction
+ 
+ func Test_terminal_nested_autocmd()
+   new
+   call setline(1, range(500))
+   $
+   let lastline = line('.')
+ 
+   augroup TermTest
+ autocmd BufFilePost * call On_BufFilePost()
+ autocmd User UserEvent silent
+   augroup END
+ 
+   let cmd = Get_cat_123_cmd()
+   let buf = term_start(cmd, #{term_finish: 'close', hidden: 1})
+   call assert_equal(lastline, line('.'))
+ 
+   call TermWait(buf)
+   exe buf . 'bwipe'
+   call delete('Xtext')
+   augroup TermTest
+ au!
+   augroup END
+ endfunc
+ 
  
  " vim: shiftwidth=2 sts=2 expandtab
*** ../vim-8.2.2694/src/version.c   2021-04-02 18:55:52.062322762 +0200
--- src/version.c   2021-04-03 13:09:53.956267704 +0200
***
*** 752,753 
--- 752,755 
  {   /* Add new patch number below this line */
+ /**/
+ 2695,
  /**/

-- 
Microsoft is to software what McDonalds is to gourmet cooking

 /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net   \\\
///  \\\
\\\sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
 \\\help me help AIDS victims -- http://ICCF-Holland.org///

-- 
-- 
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/202104031119.133BJwTC2491492%40masaka.moolenaar.net.