To: vim_dev@googlegroups.com Subject: Patch 8.2.4635 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ 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 -- Bram@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 ///