1
0
forked from aniani/vim

patch 8.0.1029: return value of getqflist() is inconsistent

Problem:    Return value of getqflist() is inconsistent.  (Lcd47)
Solution:   Always return an "items" entry.
This commit is contained in:
Bram Moolenaar
2017-08-31 20:58:02 +02:00
parent 3d593c2dc9
commit da73253a0b
3 changed files with 11 additions and 8 deletions

View File

@@ -2536,7 +2536,7 @@ func XgetListFromText(cchar)
call assert_equal(30, l[1].lnum)
call assert_equal({}, g:Xgetlist({'text' : 10}))
call assert_equal({}, g:Xgetlist({'text' : []}))
call assert_equal([], g:Xgetlist({'text' : []}).items)
" Make sure that the quickfix stack is not modified
call assert_equal(0, g:Xgetlist({'nr' : '$'}).nr)