Test failure building 8.2.4575
Hi all, this failure appears on building 8.2.4575 gtk3 variant. The platform this time it is Linux-ppc32. Failures: From test_messages.vim: Found errors in Test_fileinfo_after_echo(): Run 1: command line..script /source/vim/vim-8.2.4575/src/vim-gtk3/testdir/runtest.vim[456]..function RunTheTest[44]..Test_fileinfo_after_echo[18]..VerifyScreenDump line 61: See dump file difference: call term_dumpdiff("testdir/failed/Test_fileinfo_after_echo.dump", "testdir/dumps/Test_fileinfo_after_echo.dump"); difference in line 1: ">
Patch 8.2.4576
Patch 8.2.4576 Problem:Vim9: error for comparing with null can be annoying. Solution: Allow comparing anything with null. (closes #9948) Files: src/vim9instr.c, src/typval.c, src/testdir/test_vim9_expr.vim *** ../vim-8.2.4575/src/vim9instr.c 2022-03-15 19:29:26.546954678 + --- src/vim9instr.c 2022-03-15 20:20:46.693330758 + *** *** 397,416 vartype_name(vartype1), vartype_name(vartype2)); return ISN_DROP; } ! switch (vartype1 == VAR_SPECIAL ? vartype2 : vartype1) ! { ! case VAR_BLOB: break; ! case VAR_CHANNEL: break; ! case VAR_DICT: break; ! case VAR_FUNC: break; ! case VAR_JOB: break; ! case VAR_LIST: break; ! case VAR_PARTIAL: break; ! case VAR_STRING: break; ! default: semsg(_(e_cannot_compare_str_with_str), ! vartype_name(vartype1), vartype_name(vartype2)); !return ISN_DROP; ! } isntype = ISN_COMPARENULL; } --- 397,404 vartype_name(vartype1), vartype_name(vartype2)); return ISN_DROP; } ! // although comparing null with number, float or bool is not useful, we ! // allow it isntype = ISN_COMPARENULL; } *** ../vim-8.2.4575/src/typval.c2022-03-10 12:20:48.538552976 + --- src/typval.c2022-03-15 20:21:05.533354481 + *** *** 1417,1428 default: break; } } ! if (!in_vim9script()) ! return FALSE; // backwards compatible ! ! semsg(_(e_cannot_compare_str_with_str), !vartype_name(tv1->v_type), vartype_name(tv2->v_type)); ! return MAYBE; } /* --- 1417,1425 default: break; } } ! // although comparing null with number, float or bool is not very usefule ! // we won't give an error ! return FALSE; } /* *** ../vim-8.2.4575/src/testdir/test_vim9_expr.vim 2022-03-10 20:01:47.119865247 + --- src/testdir/test_vim9_expr.vim 2022-03-15 20:12:30.830004374 + *** *** 716,721 --- 716,750 g:null_dict = test_null_dict() g:not_null_list = [] var lines =<< trim END + assert_false(true == null) + assert_false(false == null) + assert_false(null == true) + assert_false(null == false) + assert_true(true != null) + assert_true(false != null) + assert_true(null != true) + assert_true(null != false) + + assert_false(123 == null) + assert_false(0 == null) + assert_false(null == 123) + assert_false(null == 0) + assert_true(123 != null) + assert_true(0 != null) + assert_true(null != 123) + assert_true(null != 0) + + if has('float') + assert_false(12.3 == null) + assert_false(0.0 == null) + assert_false(null == 12.3) + assert_false(null == 0.0) + assert_true(12.3 != null) + assert_true(0.0 != null) + assert_true(null != 12.3) + assert_true(null != 0.0) + endif + assert_true(test_null_blob() == v:null) assert_true(null_blob == null) assert_true(v:null == test_null_blob()) *** *** 818,833 assert_equal(null_function, d.f) END v9.CheckDefAndScriptSuccess(lines) - - v9.CheckDefAndScriptFailure(['echo 123 == v:null'], 'E1072: Cannot compare number with special') - v9.CheckDefAndScriptFailure(['echo v:null == 123'], 'E1072: Cannot compare special with number') - v9.CheckDefAndScriptFailure(['echo 123 != v:null'], 'E1072: Cannot compare number with special') - v9.CheckDefAndScriptFailure(['echo v:null != 123'], 'E1072: Cannot compare special with number') - v9.CheckDefAndScriptFailure(['echo true == v:null'], 'E1072: Cannot compare bool with special') - v9.CheckDefAndScriptFailure(['echo v:null == true'], 'E1072: Cannot compare special with bool') - v9.CheckDefAndScriptFailure(['echo true != v:null'], 'E1072: Cannot compare bool with special') - v9.CheckDefAndScriptFailure(['echo v:null != true'], 'E1072: Cannot compare special with bool') - v9.CheckDefAndScriptFailure(['echo false == v:null'], 'E1072: Cannot compare bool with special') enddef def Test_expr4_compare_none() --- 847,852 *** ../vim-8.2.4575/src/version.c 2022-03-15 19:29:26.546954678 + --- src/version.c 2022-03-15 20:04:58.915011429 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4576, /**/ -- Women are probably the main cause of free software starvation. /// Bram Moolenaar -- b...@moolenaar.net -- http://www.Moolenaar.net \\\ /// \\\ \\\sponsor Vim, vote for features --
Re: Test Failure building 8.2.4575
Elimar Riesebieter wrote: > Environment: > Linux, tmux, clang-13, amd64 > > building 8.2.4575 gives me: > > Failures: > From test_vim9_script.vim: > Found errors in Test_profile_with_lambda(): > Caught exception in Test_profile_with_lambda(): Vim(call):E484: Can't > open file Xdidprofile @ command line..script > /source/vim/vim-8.2.4574/src/vim-gtk3/testdir/runtest.vim[456]..function > RunTheTest[44]..Test_profile_with_lambda, line 53 Fixed with patch 8.2.4575. Was a bit of a puzzle why this was failing. Turns out there were three reasons. -- God made the integers; all else is the work of Man. -- Kronecker /// 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/20220315193402.01F661C42FC%40moolenaar.net.
Test Failure building 8.2.4575
Hi all, Environment: Linux, tmux, clang-13, amd64 building 8.2.4575 gives me: Failures: From test_vim9_script.vim: Found errors in Test_profile_with_lambda(): Caught exception in Test_profile_with_lambda(): Vim(call):E484: Can't open file Xdidprofile @ command line..script /source/vim/vim-8.2.4574/src/vim-gtk3/testdir/runtest.vim[456]..function RunTheTest[44]..Test_profile_with_lambda, line 53 Elimar -- 355/113: Not the famous irrational number pi, but an incredible simulation! -unknown -- -- 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/20220315193024.usp2snqpkfbokx2g%40baumbart.home.lxtec.de.
Patch 8.2.4575
Patch 8.2.4575 Problem:Vim9: test for profiling still fails. Solution: Update flags for profiling and breakpoints when obtaining the compile type. Do not set the FC_CLOSURE flag for a toplevel function. Files: src/vim.h, src/vim9compile.c, src/proto/vim9compile.pro, src/eval.c, src/vim9execute.c, src/vim9expr.c, src/vim9instr.c, src/vim9.h *** ../vim-8.2.4574/src/vim.h 2022-03-14 19:24:41.867926390 + --- src/vim.h 2022-03-15 18:18:03.789486166 + *** *** 1839,1858 CT_DEBUG // use df_instr_debug, overrules CT_PROFILE } compiletype_T; - // Keep in sync with INSTRUCTIONS(). - #ifdef FEAT_PROFILE - # define COMPILE_TYPE(ufunc) (debug_break_level > 0 \ - || may_break_in_function(ufunc) \ - ? CT_DEBUG \ - : do_profiling == PROF_YES && (ufunc)->uf_profiling \ - ? CT_PROFILE : CT_NONE) - #else - # define COMPILE_TYPE(ufunc) debug_break_level > 0 \ - || may_break_in_function(ufunc) \ - ? CT_DEBUG \ - : CT_NONE - #endif - /* * When compiling with 32 bit Perl time_t is 32 bits in the Perl code but 64 * bits elsewhere. That causes memory corruption. Define time_T and use it --- 1839,1844 *** ../vim-8.2.4574/src/vim9compile.c 2022-03-15 15:57:00.422428459 + --- src/vim9compile.c 2022-03-15 19:25:13.328140346 + *** *** 913,920 } } ! update_has_breakpoint(ufunc); ! compile_type = COMPILE_TYPE(ufunc); #ifdef FEAT_PROFILE // If the outer function is profiled, also compile the nested function for // profiling. --- 913,919 } } ! compile_type = get_compile_type(ufunc); #ifdef FEAT_PROFILE // If the outer function is profiled, also compile the nested function for // profiling. *** *** 2475,2480 --- 2474,2503 return r; } + /* + * Get the compilation type that should be used for "ufunc". + * Keep in sync with INSTRUCTIONS(). + */ + compiletype_T + get_compile_type(ufunc_T *ufunc) + { + // Update uf_has_breakpoint if needed. + update_has_breakpoint(ufunc); + + if (debug_break_level > 0 || may_break_in_function(ufunc)) + return CT_DEBUG; + #ifdef FEAT_PROFILE + if (do_profiling == PROF_YES) + { + if (!ufunc->uf_profiling && has_profiling(FALSE, ufunc->uf_name, NULL)) + func_do_profile(ufunc); + if (ufunc->uf_profiling) + return CT_PROFILE; + } + #endif + return CT_NONE; + } + /* * Add a function to the list of :def functions. *** ../vim-8.2.4574/src/proto/vim9compile.pro 2022-02-13 21:51:02.388484128 + --- src/proto/vim9compile.pro 2022-03-15 18:35:41.131618176 + *** *** 23,28 --- 23,29 int compile_assign_lhs(char_u *var_start, lhs_T *lhs, int cmdidx, int is_decl, int heredoc, int oplen, cctx_T *cctx); int compile_load_lhs_with_index(lhs_T *lhs, char_u *var_start, cctx_T *cctx); int compile_assign_unlet(char_u *var_start, lhs_T *lhs, int is_assign, type_T *rhs_type, cctx_T *cctx); + compiletype_T get_compile_type(ufunc_T *ufunc); int compile_def_function(ufunc_T *ufunc, int check_return_type, compiletype_T compile_type, cctx_T *outer_cctx); void set_function_type(ufunc_T *ufunc); void unlink_def_function(ufunc_T *ufunc); *** ../vim-8.2.4574/src/eval.c 2022-03-13 13:12:23.767131845 + --- src/eval.c 2022-03-15 18:35:46.019608561 + *** *** 3794,3801 // This is recognized in compile_return(). if (ufunc->uf_ret_type->tt_type == VAR_VOID) ufunc->uf_ret_type = _unknown; ! if (compile_def_function(ufunc, !FALSE, COMPILE_TYPE(ufunc), NULL) == FAIL) { clear_tv(rettv); ret = FAIL; --- 3794,3801 // This is recognized in compile_return(). if (ufunc->uf_ret_type->tt_type == VAR_VOID) ufunc->uf_ret_type = _unknown; ! if (compile_def_function(ufunc, FALSE, ! get_compile_type(ufunc), NULL) == FAIL) { clear_tv(rettv); ret = FAIL; *** ../vim-8.2.4574/src/vim9execute.c 2022-03-15 15:57:00.426428445 + --- src/vim9execute.c 2022-03-15 18:54:30.580371785 + *** *** 284,289 --- 284,290 estack_T *entry; funclocal_T *floc = NULL; int res = OK; + compiletype_T compile_type; if (dfunc->df_deleted) { *** *** 309,322 } #endif - // Update uf_has_breakpoint if needed. - update_has_breakpoint(ufunc); -
Patch 8.2.4574
Patch 8.2.4574 Problem:Vim9: test for profiling fails. Solution: Mark function for profiling earlier to avoid E1271. Files: src/testdir/test_vim9_script.vim *** ../vim-8.2.4573/src/testdir/test_vim9_script.vim2022-03-14 10:50:16.382185007 + --- src/testdir/test_vim9_script.vim2022-03-15 16:12:32.167658264 + *** *** 3944,3956 def Profile() profile start Xprofile.log profile func ProfiledWithLambda ! ProfiledWithLambda() ! profile func ProfiledNested ProfiledNested() ! # Also profile the nested function. Use a different function, although the ! # contents is the same, to make sure it was not already compiled. profile func * g:ProfiledNestedProfiled() --- 3944,3956 def Profile() profile start Xprofile.log profile func ProfiledWithLambda ! # mark ProfiledNested for profiling to avoid E1271 profile func ProfiledNested + ProfiledWithLambda() ProfiledNested() ! # Also profile the nested function. Use a different function, although ! # the contents is the same, to make sure it was not already compiled. profile func * g:ProfiledNestedProfiled() *** ../vim-8.2.4573/src/version.c 2022-03-15 15:57:00.426428445 + --- src/version.c 2022-03-15 16:13:31.135515370 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4574, /**/ -- hundred-and-one symptoms of being an internet addict: 270. You are subscribed to a mailing list for every piece of software you use. /// 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/20220315161720.0E2371C42FC%40moolenaar.net.
Patch 8.2.4573
Patch 8.2.4573 Problem:A nested function (closure) is compiled for debugging without context. Solution: Check if a nested function is marked for debugging before compiling it. Give an error when trying to compile a closure without its context. (closes #9951) Files: src/vim9compile.c, src/vim9execute.c, src/proto/vim9execute.pro, src/vim9expr.c, src/errors.h *** ../vim-8.2.4572/src/vim9compile.c 2022-03-13 13:12:23.767131845 + --- src/vim9compile.c 2022-03-15 15:36:29.559231314 + *** *** 913,918 --- 913,919 } } + update_has_breakpoint(ufunc); compile_type = COMPILE_TYPE(ufunc); #ifdef FEAT_PROFILE // If the outer function is profiled, also compile the nested function for *** *** 2579,2584 --- 2580,2592 new_def_function = TRUE; } + if ((ufunc->uf_flags & FC_CLOSURE) && outer_cctx == NULL) + { + semsg(_(e_compiling_closure_without_context_str), + printable_func_name(ufunc)); + return FAIL; + } + ufunc->uf_def_status = UF_COMPILING; CLEAR_FIELD(cctx); *** ../vim-8.2.4572/src/vim9execute.c 2022-03-10 20:47:38.553606225 + --- src/vim9execute.c 2022-03-15 15:03:14.528263758 + *** *** 152,158 * If debug_tick changed check if "ufunc" has a breakpoint and update * "uf_has_breakpoint". */ ! static void update_has_breakpoint(ufunc_T *ufunc) { if (ufunc->uf_debug_tick != debug_tick) --- 152,158 * If debug_tick changed check if "ufunc" has a breakpoint and update * "uf_has_breakpoint". */ ! void update_has_breakpoint(ufunc_T *ufunc) { if (ufunc->uf_debug_tick != debug_tick) *** ../vim-8.2.4572/src/proto/vim9execute.pro 2021-12-14 18:14:34.125509146 + --- src/proto/vim9execute.pro 2022-03-15 15:03:47.076206565 + *** *** 1,5 --- 1,6 /* vim9execute.c */ void to_string_error(vartype_T vartype); + void update_has_breakpoint(ufunc_T *ufunc); void funcstack_check_refcount(funcstack_T *funcstack); int set_ref_in_funcstacks(int copyID); char_u *char_from_string(char_u *str, varnumber_T index); *** ../vim-8.2.4572/src/vim9expr.c 2022-03-08 13:18:10.809020782 + --- src/vim9expr.c 2022-03-15 15:24:30.895849990 + *** *** 1007,1012 --- 1007,1020 ) compile_def_function(ufunc, FALSE, CT_NONE, cctx); + // if the outer function is not compiled for debugging, this one might be + if (cctx->ctx_compile_type != CT_DEBUG) + { + update_has_breakpoint(ufunc); + if (COMPILE_TYPE(ufunc) == CT_DEBUG) + compile_def_function(ufunc, FALSE, CT_DEBUG, cctx); + } + // The last entry in evalarg.eval_tofree_ga is a copy of the last line and // "*arg" may point into it. Point into the original line to avoid a // dangling pointer. *** ../vim-8.2.4572/src/errors.h2022-03-05 22:07:29.133523260 + --- src/errors.h2022-03-15 15:33:20.927428392 + *** *** 3249,3251 --- 3249,3255 #endif EXTERN char e_cannot_use_s_backslash_in_vim9_script[] INIT(= N_("E1270: Cannot use :s\\/sub/ in Vim9 script")); + #ifdef FEAT_EVAL + EXTERN char e_compiling_closure_without_context_str[] + INIT(= N_("E1271: compiling closure without context: %s")); + #endif *** ../vim-8.2.4572/src/version.c 2022-03-15 12:28:06.041374341 + --- src/version.c 2022-03-15 15:03:40.172218737 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4573, /**/ -- hundred-and-one symptoms of being an internet addict: 269. You wonder how you can make your dustbin produce Sesame Street's Oscar's the Garbage Monster song when you empty it. /// 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/20220315160341.C75B21C45E0%40moolenaar.net.
Patch 8.2.4572
Patch 8.2.4572 Problem:Vim9: return type "any" is sometimes changed to first returned type. (Virginia Senioria) Solution: Do not change the return type if declared as "any". (closes #9949) Files: src/vim9cmds.c, src/testdir/test_vim9_func.vim *** ../vim-8.2.4571/src/vim9cmds.c 2022-03-12 14:51:12.765797435 + --- src/vim9cmds.c 2022-03-15 12:14:13.718302120 + *** *** 2258,2265 // return type here. stack_type = get_type_on_stack(cctx, 0); if ((check_return_type && (cctx->ctx_ufunc->uf_ret_type == NULL ! || cctx->ctx_ufunc->uf_ret_type == _unknown ! || cctx->ctx_ufunc->uf_ret_type == _any)) || (!check_return_type && cctx->ctx_ufunc->uf_ret_type == _unknown)) { --- 2258,2264 // return type here. stack_type = get_type_on_stack(cctx, 0); if ((check_return_type && (cctx->ctx_ufunc->uf_ret_type == NULL ! || cctx->ctx_ufunc->uf_ret_type == _unknown)) || (!check_return_type && cctx->ctx_ufunc->uf_ret_type == _unknown)) { *** ../vim-8.2.4571/src/testdir/test_vim9_func.vim 2022-03-12 21:28:18.532257720 + --- src/testdir/test_vim9_func.vim 2022-03-15 12:26:03.569478456 + *** *** 535,540 --- 535,564 v9.CheckScriptSuccess(lines) enddef + def Test_return_any_two_types() + var lines =<< trim END + vim9script + + def G(Fn: func(string): any) + g:result = Fn("hello") + enddef + + def F(a: number, b: string): any + echo b + if a > 0 + return 1 + else + return [] + endif + enddef + + G(function(F, [1])) + END + v9.CheckScriptSuccess(lines) + assert_equal(1, g:result) + unlet g:result + enddef + func s:Increment() let g:counter += 1 endfunc *** ../vim-8.2.4571/src/version.c 2022-03-15 12:00:18.243752058 + --- src/version.c 2022-03-15 12:15:26.810166064 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4572, /**/ -- Two fish in a tank. One says to the other: "Do you know how to drive this thing?" /// 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/20220315122914.528341C42FC%40moolenaar.net.
Patch 8.2.4571
Patch 8.2.4571 Problem:Not all gdb files are recognized. Solution: Add a few more patterns for gdb. (Jade Lovelace, closes #9956) Files: runtime/filetype.vim, src/testdir/test_filetype.vim *** ../vim-8.2.4570/runtime/filetype.vim2022-02-24 17:59:05.256644873 + --- runtime/filetype.vim2022-03-15 11:55:43.072136461 + *** *** 668,674 au BufNewFile,BufRead *.fsi,*.fsx setf fsharp " GDB command files ! au BufNewFile,BufRead .gdbinit,gdbinitsetf gdb " GDMO au BufNewFile,BufRead *.mo,*.gdmo setf gdmo --- 668,674 au BufNewFile,BufRead *.fsi,*.fsx setf fsharp " GDB command files ! au BufNewFile,BufRead .gdbinit,gdbinit,.gdbearlyinit,gdbearlyinit,*.gdb setf gdb " GDMO au BufNewFile,BufRead *.mo,*.gdmo setf gdmo *** ../vim-8.2.4570/src/testdir/test_filetype.vim 2022-02-25 17:40:59.319948279 + --- src/testdir/test_filetype.vim 2022-03-15 11:55:43.072136461 + *** *** 196,202 \ 'fstab': ['fstab', 'mtab'], \ 'fusion': ['file.fusion'], \ 'fvwm': ['/.fvwm/file', 'any/.fvwm/file'], ! \ 'gdb': ['.gdbinit', 'gdbinit'], \ 'gdresource': ['file.tscn', 'file.tres'], \ 'gdscript': ['file.gd'], \ 'gdmo': ['file.mo', 'file.gdmo'], --- 196,202 \ 'fstab': ['fstab', 'mtab'], \ 'fusion': ['file.fusion'], \ 'fvwm': ['/.fvwm/file', 'any/.fvwm/file'], ! \ 'gdb': ['.gdbinit', 'gdbinit', 'file.gdb', '.config/gdbearlyinit', '.gdbearlyinit'], \ 'gdresource': ['file.tscn', 'file.tres'], \ 'gdscript': ['file.gd'], \ 'gdmo': ['file.mo', 'file.gdmo'], *** ../vim-8.2.4570/src/version.c 2022-03-15 10:53:01.551462719 + --- src/version.c 2022-03-15 11:58:44.035892382 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4571, /**/ -- Error 42: No errors /// 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/20220315120059.4833E1C42FC%40moolenaar.net.
Patch 8.2.4570
Patch 8.2.4570 Problem:No command line completion for :profile and :profdel. Solution: Implement completion. (Yegappan Lakshmanan, closes #9955) Files: src/cmdexpand.c, src/profiler.c, src/testdir/test_cmdline.vim, src/testdir/test_profile.vim *** ../vim-8.2.4569/src/cmdexpand.c 2022-03-14 19:24:41.867926390 + --- src/cmdexpand.c 2022-03-15 10:47:42.332248148 + *** *** 1606,1612 static enum { EXP_BREAKPT_ADD, // expand ":breakadd" sub-commands ! EXP_BREAKPT_DEL // expand ":breakdel" sub-commands } breakpt_expand_what; /* --- 1606,1613 static enum { EXP_BREAKPT_ADD, // expand ":breakadd" sub-commands ! EXP_BREAKPT_DEL, // expand ":breakdel" sub-commands ! EXP_PROFDEL // expand ":profdel" sub-commands } breakpt_expand_what; /* *** *** 1623,1638 if (cmdidx == CMD_breakadd) breakpt_expand_what = EXP_BREAKPT_ADD; ! else breakpt_expand_what = EXP_BREAKPT_DEL; p = skipwhite(arg); if (*p == NUL) return NULL; subcmd_start = p; ! if (STRNCMP("file ", p, 5) == 0 || ! STRNCMP("func ", p, 5) == 0) { // :breakadd file [lnum] // :breakadd func [lnum] --- 1624,1640 if (cmdidx == CMD_breakadd) breakpt_expand_what = EXP_BREAKPT_ADD; ! else if (cmdidx == CMD_breakdel) breakpt_expand_what = EXP_BREAKPT_DEL; + else + breakpt_expand_what = EXP_PROFDEL; p = skipwhite(arg); if (*p == NUL) return NULL; subcmd_start = p; ! if (STRNCMP("file ", p, 5) == 0 || STRNCMP("func ", p, 5) == 0) { // :breakadd file [lnum] // :breakadd func [lnum] *** *** 2025,2030 --- 2027,2033 #ifdef FEAT_EVAL case CMD_breakadd: + case CMD_profdel: case CMD_breakdel: return set_context_in_breakadd_cmd(xp, arg, cmdidx); #endif *** *** 2432,2444 if (idx >=0 && idx <= 3) { if (breakpt_expand_what == EXP_BREAKPT_ADD) return (char_u *)opts[idx]; ! else { if (idx <= 2) return (char_u *)opts[idx + 1]; } } return NULL; } --- 2435,2455 if (idx >=0 && idx <= 3) { + // breakadd {expr, file, func, here} if (breakpt_expand_what == EXP_BREAKPT_ADD) return (char_u *)opts[idx]; ! else if (breakpt_expand_what == EXP_BREAKPT_DEL) { + // breakdel {func, file, here} if (idx <= 2) return (char_u *)opts[idx + 1]; } + else + { + // profdel {func, file} + if (idx <= 1) + return (char_u *)opts[idx + 1]; + } } return NULL; } *** ../vim-8.2.4569/src/profiler.c 2022-01-05 16:08:59.524426437 + --- src/profiler.c 2022-03-15 10:47:42.332248148 + *** *** 376,382 { case PEXP_SUBCMD: return (char_u *)pexpand_cmds[idx]; - // case PEXP_FUNC: TODO default: return NULL; } --- 376,381 *** *** 399,412 if (*end_subcmd == NUL) return; ! if (end_subcmd - arg == 5 && STRNCMP(arg, "start", 5) == 0) { xp->xp_context = EXPAND_FILES; xp->xp_pattern = skipwhite(end_subcmd); return; } - // TODO: expand function names after "func" xp->xp_context = EXPAND_NOTHING; } --- 398,417 if (*end_subcmd == NUL) return; ! if ((end_subcmd - arg == 5 && STRNCMP(arg, "start", 5) == 0) ! || (end_subcmd - arg == 4 && STRNCMP(arg, "file", 4) == 0)) { xp->xp_context = EXPAND_FILES; xp->xp_pattern = skipwhite(end_subcmd); return; } + else if (end_subcmd - arg == 4 && STRNCMP(arg, "func", 4) == 0) + { + xp->xp_context = EXPAND_USER_FUNC; + xp->xp_pattern = skipwhite(end_subcmd); + return; + } xp->xp_context = EXPAND_NOTHING; } *** ../vim-8.2.4569/src/testdir/test_cmdline.vim2022-03-14 19:24:41.867926390 + --- src/testdir/test_cmdline.vim2022-03-15 10:47:42.332248148 + *** *** 3158,3164 call assert_equal("\"breakdel here Xtest", @:) call feedkeys(":breakdel here \\\"\", 'tx') call assert_equal("\"breakdel here ", @:) - endfunc " vim: shiftwidth=2 sts=2 expandtab --- 3158,3163 *** ../vim-8.2.4569/src/testdir/test_profile.vim2022-01-29 21:45:30.485921485 + --- src/testdir/test_profile.vim2022-03-15 10:47:42.332248148 + *** *** 434,439 --- 434,480 call feedkeys(":profile start test_prof\\\"\", 'tx') call assert_match('^"profile start.* test_profile\.vim', @:) + + call feedkeys(":profile file test_prof\\\"\", 'tx') + call
Patch 8.2.4569
Patch 8.2.4569 Problem:Coverity warning for not using a return value. Solution: Add "(void)". Files: src/popupwin.c *** ../vim-8.2.4568/src/popupwin.c 2022-01-29 15:19:19.546172430 + --- src/popupwin.c 2022-03-15 10:19:59.287521481 + *** *** 3738,3744 { // compute the position in the buffer line // from the position in the window ! mouse_comp_pos(wp, _cp, _cp, , plines_cache); redrawWinline(wp, lnum); } --- 3738,3744 { // compute the position in the buffer line // from the position in the window ! (void)mouse_comp_pos(wp, _cp, _cp, , plines_cache); redrawWinline(wp, lnum); } *** ../vim-8.2.4568/src/version.c 2022-03-15 09:46:50.757054758 + --- src/version.c 2022-03-15 10:20:41.583486663 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4569, /**/ -- hundred-and-one symptoms of being an internet addict: 266. You hear most of your jokes via e-mail instead of in person. /// 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/20220315102324.191951C42FC%40moolenaar.net.
Patch 8.2.4568
Patch 8.2.4568 Problem:getmousepos() does not compute the column below the last line. Solution: Also compute the column when the mouse is below the last line. (Sean Dewar, closes #9946) Files: src/mouse.c, src/testdir/test_functions.vim *** ../vim-8.2.4567/src/mouse.c 2022-03-13 19:08:44.685537723 + --- src/mouse.c 2022-03-15 09:40:45.194237569 + *** *** 3099,3106 col -= left_off; if (row >= 0 && row < wp->w_height && col >= 0 && col < wp->w_width) { ! if (!mouse_comp_pos(wp, , , , NULL)) ! col = vcol2col(wp, lnum, col); column = col + 1; } } --- 3099,3106 col -= left_off; if (row >= 0 && row < wp->w_height && col >= 0 && col < wp->w_width) { ! (void)mouse_comp_pos(wp, , , , NULL); ! col = vcol2col(wp, lnum, col); column = col + 1; } } *** ../vim-8.2.4567/src/testdir/test_functions.vim 2022-03-13 15:52:34.173429915 + --- src/testdir/test_functions.vim 2022-03-15 09:40:27.914293988 + *** *** 2783,2788 --- 2783,2811 \ line: 1, \ column: 8, \ }, getmousepos()) + + " If the mouse is positioned past the last buffer line, "line" and "column" + " should act like it's positioned on the last buffer line. + call test_setmouse(2, 25) + call assert_equal(#{ + \ screenrow: 2, + \ screencol: 25, + \ winid: win_getid(), + \ winrow: 2, + \ wincol: 25, + \ line: 1, + \ column: 4, + \ }, getmousepos()) + call test_setmouse(2, 50) + call assert_equal(#{ + \ screenrow: 2, + \ screencol: 50, + \ winid: win_getid(), + \ winrow: 2, + \ wincol: 50, + \ line: 1, + \ column: 8, + \ }, getmousepos()) bwipe! endfunc *** ../vim-8.2.4567/src/version.c 2022-03-14 20:46:37.461884474 + --- src/version.c 2022-03-15 09:45:04.625396409 + *** *** 752,753 --- 752,755 { /* Add new patch number below this line */ + /**/ + 4568, /**/ -- hundred-and-one symptoms of being an internet addict: 265. Your reason for not staying in touch with family is that they do not have e-mail addresses. /// 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/20220315094737.187D31C45E0%40moolenaar.net.