Karsten Hopp c57dc2
To: vim_dev@googlegroups.com
Karsten Hopp c57dc2
Subject: Patch 7.4.585
Karsten Hopp c57dc2
Fcc: outbox
Karsten Hopp c57dc2
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp c57dc2
Mime-Version: 1.0
Karsten Hopp c57dc2
Content-Type: text/plain; charset=UTF-8
Karsten Hopp c57dc2
Content-Transfer-Encoding: 8bit
Karsten Hopp c57dc2
------------
Karsten Hopp c57dc2
Karsten Hopp c57dc2
Patch 7.4.585
Karsten Hopp c57dc2
Problem:    Range for :bdelete does not work. (Ronald Schild)
Karsten Hopp c57dc2
Solution:   Also allow unloaded buffers.
Karsten Hopp c57dc2
Files:	    src/ex_cmds.h, src/testdir/test_command_count.in,
Karsten Hopp c57dc2
	    src/testdir/test_command_count.ok
Karsten Hopp c57dc2
Karsten Hopp c57dc2
Karsten Hopp c57dc2
*** ../vim-7.4.584/src/ex_cmds.h	2015-01-07 16:52:53.506792420 +0100
Karsten Hopp c57dc2
--- src/ex_cmds.h	2015-01-20 13:22:16.778245812 +0100
Karsten Hopp c57dc2
***************
Karsten Hopp c57dc2
*** 173,179 ****
Karsten Hopp c57dc2
  			ADDR_LINES),
Karsten Hopp c57dc2
  EX(CMD_bdelete,		"bdelete",	ex_bunload,
Karsten Hopp c57dc2
  			BANG|RANGE|NOTADR|BUFNAME|COUNT|EXTRA|TRLBAR,
Karsten Hopp c57dc2
! 			ADDR_LOADED_BUFFERS),
Karsten Hopp c57dc2
  EX(CMD_behave,		"behave",	ex_behave,
Karsten Hopp c57dc2
  			NEEDARG|WORD1|TRLBAR|CMDWIN,
Karsten Hopp c57dc2
  			ADDR_LINES),
Karsten Hopp c57dc2
--- 173,179 ----
Karsten Hopp c57dc2
  			ADDR_LINES),
Karsten Hopp c57dc2
  EX(CMD_bdelete,		"bdelete",	ex_bunload,
Karsten Hopp c57dc2
  			BANG|RANGE|NOTADR|BUFNAME|COUNT|EXTRA|TRLBAR,
Karsten Hopp c57dc2
! 			ADDR_BUFFERS),
Karsten Hopp c57dc2
  EX(CMD_behave,		"behave",	ex_behave,
Karsten Hopp c57dc2
  			NEEDARG|WORD1|TRLBAR|CMDWIN,
Karsten Hopp c57dc2
  			ADDR_LINES),
Karsten Hopp c57dc2
*** ../vim-7.4.584/src/testdir/test_command_count.in	2015-01-20 12:39:35.918399822 +0100
Karsten Hopp c57dc2
--- src/testdir/test_command_count.in	2015-01-20 13:21:55.510479070 +0100
Karsten Hopp c57dc2
***************
Karsten Hopp c57dc2
*** 92,102 ****
Karsten Hopp c57dc2
  :call append(0, g:lines)
Karsten Hopp c57dc2
  :unlet g:lines
Karsten Hopp c57dc2
  :w|bd
Karsten Hopp c57dc2
- :se hidden
Karsten Hopp c57dc2
  :b1
Karsten Hopp c57dc2
  ENDTEST
Karsten Hopp c57dc2
  
Karsten Hopp c57dc2
  STARTTEST
Karsten Hopp c57dc2
  :only!
Karsten Hopp c57dc2
  :let g:lines = []
Karsten Hopp c57dc2
  :%argd
Karsten Hopp c57dc2
--- 92,128 ----
Karsten Hopp c57dc2
  :call append(0, g:lines)
Karsten Hopp c57dc2
  :unlet g:lines
Karsten Hopp c57dc2
  :w|bd
Karsten Hopp c57dc2
  :b1
Karsten Hopp c57dc2
  ENDTEST
Karsten Hopp c57dc2
  
Karsten Hopp c57dc2
  STARTTEST
Karsten Hopp c57dc2
+ :let g:lines = []
Karsten Hopp c57dc2
+ :func BufStatus()
Karsten Hopp c57dc2
+ :  call add(g:lines, 'aaa: ' . buflisted(g:buf_aaa) . ' bbb: ' . buflisted(g:buf_bbb) . ' ccc: ' . buflisted(g:buf_ccc))
Karsten Hopp c57dc2
+ :endfunc
Karsten Hopp c57dc2
+ :se nohidden
Karsten Hopp c57dc2
+ :e aaa
Karsten Hopp c57dc2
+ :let buf_aaa = bufnr('%')
Karsten Hopp c57dc2
+ :e bbb
Karsten Hopp c57dc2
+ :let buf_bbb = bufnr('%')
Karsten Hopp c57dc2
+ :e ccc
Karsten Hopp c57dc2
+ :let buf_ccc = bufnr('%')
Karsten Hopp c57dc2
+ :b1
Karsten Hopp c57dc2
+ :call BufStatus()
Karsten Hopp c57dc2
+ :exe buf_bbb . "," . buf_ccc . "bdelete"
Karsten Hopp c57dc2
+ :call BufStatus()
Karsten Hopp c57dc2
+ :exe buf_aaa . "bdelete"
Karsten Hopp c57dc2
+ :call BufStatus()
Karsten Hopp c57dc2
+ :e! test.out
Karsten Hopp c57dc2
+ :call append('$', g:lines)
Karsten Hopp c57dc2
+ :unlet g:lines
Karsten Hopp c57dc2
+ :delfunc BufStatus
Karsten Hopp c57dc2
+ :w|bd
Karsten Hopp c57dc2
+ :b1
Karsten Hopp c57dc2
+ ENDTEST
Karsten Hopp c57dc2
+ 
Karsten Hopp c57dc2
+ STARTTEST
Karsten Hopp c57dc2
+ :se hidden
Karsten Hopp c57dc2
  :only!
Karsten Hopp c57dc2
  :let g:lines = []
Karsten Hopp c57dc2
  :%argd
Karsten Hopp c57dc2
*** ../vim-7.4.584/src/testdir/test_command_count.ok	2015-01-14 11:24:51.851582151 +0100
Karsten Hopp c57dc2
--- src/testdir/test_command_count.ok	2015-01-20 13:16:03.358341733 +0100
Karsten Hopp c57dc2
***************
Karsten Hopp c57dc2
*** 28,35 ****
Karsten Hopp c57dc2
  $+tabe E16: Invalid range
Karsten Hopp c57dc2
  0tabm x
Karsten Hopp c57dc2
  
Karsten Hopp c57dc2
  argdo: c d e
Karsten Hopp c57dc2
  windo: 2 3 4
Karsten Hopp c57dc2
! bufdo: 2 3 4 5 6 7 8 9 10 12
Karsten Hopp c57dc2
  bufdo: 3 4 5 6 7
Karsten Hopp c57dc2
  tabdo: 2 3 4
Karsten Hopp c57dc2
--- 28,38 ----
Karsten Hopp c57dc2
  $+tabe E16: Invalid range
Karsten Hopp c57dc2
  0tabm x
Karsten Hopp c57dc2
  
Karsten Hopp c57dc2
+ aaa: 1 bbb: 1 ccc: 1
Karsten Hopp c57dc2
+ aaa: 1 bbb: 0 ccc: 0
Karsten Hopp c57dc2
+ aaa: 0 bbb: 0 ccc: 0
Karsten Hopp c57dc2
  argdo: c d e
Karsten Hopp c57dc2
  windo: 2 3 4
Karsten Hopp c57dc2
! bufdo: 2 3 4 5 6 7 8 9 10 15
Karsten Hopp c57dc2
  bufdo: 3 4 5 6 7
Karsten Hopp c57dc2
  tabdo: 2 3 4
Karsten Hopp c57dc2
*** ../vim-7.4.584/src/version.c	2015-01-20 12:39:35.918399822 +0100
Karsten Hopp c57dc2
--- src/version.c	2015-01-20 13:27:49.438597595 +0100
Karsten Hopp c57dc2
***************
Karsten Hopp c57dc2
*** 743,744 ****
Karsten Hopp c57dc2
--- 743,746 ----
Karsten Hopp c57dc2
  {   /* Add new patch number below this line */
Karsten Hopp c57dc2
+ /**/
Karsten Hopp c57dc2
+     585,
Karsten Hopp c57dc2
  /**/
Karsten Hopp c57dc2
Karsten Hopp c57dc2
-- 
Karsten Hopp c57dc2
I AM THANKFUL...
Karsten Hopp c57dc2
...for a lawn that needs mowing, windows that need cleaning
Karsten Hopp c57dc2
and gutters that need fixing because it means I have a home.
Karsten Hopp c57dc2
Karsten Hopp c57dc2
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp c57dc2
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp c57dc2
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp c57dc2
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///