Karsten Hopp 754031
To: vim_dev@googlegroups.com
Karsten Hopp 754031
Subject: Patch 7.4.150
Karsten Hopp 754031
Fcc: outbox
Karsten Hopp 754031
From: Bram Moolenaar <Bram@moolenaar.net>
Karsten Hopp 754031
Mime-Version: 1.0
Karsten Hopp 754031
Content-Type: text/plain; charset=UTF-8
Karsten Hopp 754031
Content-Transfer-Encoding: 8bit
Karsten Hopp 754031
------------
Karsten Hopp 754031
Karsten Hopp 754031
Patch 7.4.150
Karsten Hopp 754031
Problem:    :keeppatterns is not respected for :s.
Karsten Hopp 754031
Solution:   Check the keeppatterns flag. (Yasuhiro Matsumoto)
Karsten Hopp 754031
Files:	    src/search.c, src/testdir/test14.in, src/testdir/test14.ok
Karsten Hopp 754031
Karsten Hopp 754031
Karsten Hopp 754031
*** ../vim-7.4.149/src/search.c	2013-11-28 19:27:18.000000000 +0100
Karsten Hopp 754031
--- src/search.c	2014-01-14 15:44:33.000000000 +0100
Karsten Hopp 754031
***************
Karsten Hopp 754031
*** 201,207 ****
Karsten Hopp 754031
       * Save the currently used pattern in the appropriate place,
Karsten Hopp 754031
       * unless the pattern should not be remembered.
Karsten Hopp 754031
       */
Karsten Hopp 754031
!     if (!(options & SEARCH_KEEP))
Karsten Hopp 754031
      {
Karsten Hopp 754031
  	/* search or global command */
Karsten Hopp 754031
  	if (pat_save == RE_SEARCH || pat_save == RE_BOTH)
Karsten Hopp 754031
--- 201,207 ----
Karsten Hopp 754031
       * Save the currently used pattern in the appropriate place,
Karsten Hopp 754031
       * unless the pattern should not be remembered.
Karsten Hopp 754031
       */
Karsten Hopp 754031
!     if (!(options & SEARCH_KEEP) && !cmdmod.keeppatterns)
Karsten Hopp 754031
      {
Karsten Hopp 754031
  	/* search or global command */
Karsten Hopp 754031
  	if (pat_save == RE_SEARCH || pat_save == RE_BOTH)
Karsten Hopp 754031
*** ../vim-7.4.149/src/testdir/test14.in	2013-04-03 20:59:14.000000000 +0200
Karsten Hopp 754031
--- src/testdir/test14.in	2014-01-14 15:43:28.000000000 +0100
Karsten Hopp 754031
***************
Karsten Hopp 754031
*** 47,52 ****
Karsten Hopp 754031
--- 47,61 ----
Karsten Hopp 754031
  /two
Karsten Hopp 754031
  :call search('.', 'c')
Karsten Hopp 754031
  :call append(line('$'), getline('.')[col('.') - 1:])
Karsten Hopp 754031
+ :"
Karsten Hopp 754031
+ /^substitute
Karsten Hopp 754031
+ :s/foo/bar/
Karsten Hopp 754031
+ :$put =@/
Karsten Hopp 754031
+ /^substitute
Karsten Hopp 754031
+ :keeppatterns s/asdf/xyz/
Karsten Hopp 754031
+ :$put =@/
Karsten Hopp 754031
+ /^substitute
Karsten Hopp 754031
+ Y:$put =@0
Karsten Hopp 754031
  :/^search()/,$w >>test.out
Karsten Hopp 754031
  :qa!
Karsten Hopp 754031
  ENDTEST
Karsten Hopp 754031
***************
Karsten Hopp 754031
*** 81,86 ****
Karsten Hopp 754031
--- 90,96 ----
Karsten Hopp 754031
  
Karsten Hopp 754031
  foobar
Karsten Hopp 754031
  
Karsten Hopp 754031
+ substitute foo asdf
Karsten Hopp 754031
  
Karsten Hopp 754031
  one two
Karsten Hopp 754031
  search()
Karsten Hopp 754031
*** ../vim-7.4.149/src/testdir/test14.ok	2013-04-03 20:59:14.000000000 +0200
Karsten Hopp 754031
--- src/testdir/test14.ok	2014-01-14 15:46:42.000000000 +0100
Karsten Hopp 754031
***************
Karsten Hopp 754031
*** 20,22 ****
Karsten Hopp 754031
--- 20,25 ----
Karsten Hopp 754031
  1
Karsten Hopp 754031
  1
Karsten Hopp 754031
  two
Karsten Hopp 754031
+ foo
Karsten Hopp 754031
+ ^substitute
Karsten Hopp 754031
+ substitute bar xyz
Karsten Hopp 754031
*** ../vim-7.4.149/src/version.c	2014-01-14 15:24:24.000000000 +0100
Karsten Hopp 754031
--- src/version.c	2014-01-14 15:45:34.000000000 +0100
Karsten Hopp 754031
***************
Karsten Hopp 754031
*** 740,741 ****
Karsten Hopp 754031
--- 740,743 ----
Karsten Hopp 754031
  {   /* Add new patch number below this line */
Karsten Hopp 754031
+ /**/
Karsten Hopp 754031
+     150,
Karsten Hopp 754031
  /**/
Karsten Hopp 754031
Karsten Hopp 754031
-- 
Karsten Hopp 754031
hundred-and-one symptoms of being an internet addict:
Karsten Hopp 754031
158. You get a tuner card so you can watch TV while surfing.
Karsten Hopp 754031
Karsten Hopp 754031
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
Karsten Hopp 754031
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
Karsten Hopp 754031
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
Karsten Hopp 754031
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///