Patch 8.2.3810
Problem:    Vim9: expr4 test fails on MS-Windows.
Solution:   Do not give an error for a missing function name when skipping.
Files:      src/eval.c, src/testdir/test_vim9_expr.vim


*** ../vim-8.2.3809/src/eval.c  2021-12-14 18:14:34.129509139 +0000
--- src/eval.c  2021-12-14 18:57:08.960188343 +0000
***************
*** 2001,2007 ****
      // Need to make a copy, in case evaluating the arguments makes
      // the name invalid.
      s = vim_strsave(s);
!     if (s == NULL || *s == NUL || (flags & EVAL_CONSTANT))
        ret = FAIL;
      else
      {
--- 2001,2007 ----
      // Need to make a copy, in case evaluating the arguments makes
      // the name invalid.
      s = vim_strsave(s);
!     if (s == NULL || (evaluate && (*s == NUL || (flags & EVAL_CONSTANT))))
        ret = FAIL;
      else
      {
*** ../vim-8.2.3809/src/testdir/test_vim9_expr.vim      2021-08-15 
19:36:24.363246790 +0100
--- src/testdir/test_vim9_expr.vim      2021-12-14 18:54:49.672329350 +0000
***************
*** 646,653 ****
        assert_equal(false, function('g:Test_expr4_equal', [123]) == 
function('g:Test_expr4_is', [123]))
        assert_equal(false, function('g:Test_expr4_equal', [123]) == 
function('g:Test_expr4_equal', [999]))
  
!       # TODO: this unexpectedly sometimes fails on Appveyor
!       if !has('win32')
          var OneFunc: func
          var TwoFunc: func
          OneFunc = function('len')
--- 646,661 ----
        assert_equal(false, function('g:Test_expr4_equal', [123]) == 
function('g:Test_expr4_is', [123]))
        assert_equal(false, function('g:Test_expr4_equal', [123]) == 
function('g:Test_expr4_equal', [999]))
  
!       if true
!         var OneFunc: func
!         var TwoFunc: func
!         OneFunc = function('len')
!         TwoFunc = function('len')
!         assert_equal(true, OneFunc('abc') == TwoFunc('123'))
!       endif
! 
!       # check this doesn't fail when skipped
!       if false
          var OneFunc: func
          var TwoFunc: func
          OneFunc = function('len')
*** ../vim-8.2.3809/src/version.c       2021-12-14 18:14:34.129509139 +0000
--- src/version.c       2021-12-14 18:53:13.976424309 +0000
***************
*** 751,752 ****
--- 751,754 ----
  {   /* Add new patch number below this line */
+ /**/
+     3810,
  /**/

-- 
Q. What happens to programmers when they die?
A: MS-Windows programmers are reinstalled.  C++ programmers become undefined,
   anyone who refers to them will die as well. Java programmers reincarnate
   after being garbage collected, unless they are in permgen, in which case
   they become zombies.  Zimbu programmers leave a stack trace that tells us
   exactly where they died and how they got there.

 /// Bram Moolenaar -- [email protected] -- 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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/20211214185812.891211C014A%40moolenaar.net.

Raspunde prin e-mail lui