Patch 8.2.4635 (after 8.2.4634)
Problem:    Tests using null list or dict fail.
Solution:   Only use the new rules for Vim9 script.
Files:      src/evalvars.c


*** ../vim-8.2.4634/src/evalvars.c      2022-03-27 16:29:49.880153368 +0100
--- src/evalvars.c      2022-03-27 16:45:33.222267408 +0100
***************
*** 2822,2828 ****
            if (ht != &globvarht)
            {
                if (tv->v_type == VAR_DICT && tv->vval.v_dict == NULL
!                                     && type != NULL && type != &t_dict_empty)
                {
                    tv->vval.v_dict = dict_alloc();
                    if (tv->vval.v_dict != NULL)
--- 2822,2829 ----
            if (ht != &globvarht)
            {
                if (tv->v_type == VAR_DICT && tv->vval.v_dict == NULL
!                         && ((type != NULL && type != &t_dict_empty)
!                                                          || !in_vim9script()))
                {
                    tv->vval.v_dict = dict_alloc();
                    if (tv->vval.v_dict != NULL)
***************
*** 2832,2838 ****
                    }
                }
                else if (tv->v_type == VAR_LIST && tv->vval.v_list == NULL
!                                     && type != NULL && type != &t_list_empty)
                {
                    tv->vval.v_list = list_alloc();
                    if (tv->vval.v_list != NULL)
--- 2833,2840 ----
                    }
                }
                else if (tv->v_type == VAR_LIST && tv->vval.v_list == NULL
!                                   && ((type != NULL && type != &t_list_empty)
!                                                         || !in_vim9script()))
                {
                    tv->vval.v_list = list_alloc();
                    if (tv->vval.v_list != NULL)
*** ../vim-8.2.4634/src/version.c       2022-03-27 16:29:49.884153361 +0100
--- src/version.c       2022-03-27 16:50:04.061678521 +0100
***************
*** 752,753 ****
--- 752,755 ----
  {   /* Add new patch number below this line */
+ /**/
+     4635,
  /**/

-- 
ARTHUR:  You fight with the strength of many men, Sir knight.
         I am Arthur, King of the Britons.  [pause]
         I seek the finest and the bravest knights in the land to join me
         in my Court of Camelot.  [pause]
         You have proved yourself worthy; will you join me?  [pause]
         You make me sad.  So be it.  Come, Patsy.
BLACK KNIGHT:  None shall pass.
                                  The Quest for the Holy Grail (Monty Python)

 /// 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/20220327155201.525831C0C1F%40moolenaar.net.

Raspunde prin e-mail lui