Patch 8.2.1101
Problem:    No error when using wrong arguments for setqflist() or
            setloclist().
Solution:   Check for the error.
Files:      src/quickfix.c, src/testdir/test_quickfix.vim


*** ../vim-8.2.1100/src/quickfix.c      2020-06-24 20:33:59.569106308 +0200
--- src/quickfix.c      2020-06-30 22:10:00.323211147 +0200
***************
*** 7400,7405 ****
--- 7400,7413 ----
        return OK;
      }
  
+     // A dict argument cannot be specified with a non-empty list argument
+     if (list != NULL && list->lv_len != 0 && what != NULL)
+     {
+       semsg(_(e_invarg2),
+                        _("cannot have both a list and a \"what\" argument"));
+       return FAIL;
+     }
+ 
      incr_quickfix_busy();
  
      if (what != NULL)
*** ../vim-8.2.1100/src/testdir/test_quickfix.vim       2020-06-26 
20:41:35.628844696 +0200
--- src/testdir/test_quickfix.vim       2020-06-30 22:10:48.335034537 +0200
***************
*** 2360,2365 ****
--- 2360,2368 ----
      call assert_equal(['Colors'], newl2.context)
      call assert_equal('Line10', newl2.items[0].text)
      call g:Xsetlist([], 'f')
+ 
+     " Cannot specify both a non-empty list argument and a dict argument
+     call assert_fails("call g:Xsetlist([{}], ' ', {})", 'E475:')
  endfunc
  
  func Test_qf_property()
*** ../vim-8.2.1100/src/version.c       2020-06-30 22:01:58.649556937 +0200
--- src/version.c       2020-06-30 22:06:50.328146719 +0200
***************
*** 756,757 ****
--- 756,759 ----
  {   /* Add new patch number below this line */
+ /**/
+     1101,
  /**/

-- 
SOLDIER: Where did you get the coconuts?
ARTHUR:  Through ... We found them.
SOLDIER: Found them?  In Mercea.  The coconut's tropical!
                 "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
 \\\            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/202006302012.05UKCChJ983061%40masaka.moolenaar.net.

Raspunde prin e-mail lui