jkunstle / rpms / vim

Forked from rpms/vim 3 years ago
Clone
3ef2ca
To: vim_dev@googlegroups.com
3ef2ca
Subject: Patch 7.4.178
3ef2ca
Fcc: outbox
3ef2ca
From: Bram Moolenaar <Bram@moolenaar.net>
3ef2ca
Mime-Version: 1.0
3ef2ca
Content-Type: text/plain; charset=UTF-8
3ef2ca
Content-Transfer-Encoding: 8bit
3ef2ca
------------
3ef2ca
3ef2ca
Patch 7.4.178
3ef2ca
Problem:    The J command does not update '[ and '] marks. (William Gardner)
3ef2ca
Solution:   Set the marks. (Christian Brabandt)
3ef2ca
Files:	    src/ops.c
3ef2ca
3ef2ca
3ef2ca
*** ../vim-7.4.177/src/ops.c	2014-01-14 12:33:32.000000000 +0100
3ef2ca
--- src/ops.c	2014-02-11 19:22:46.538343647 +0100
3ef2ca
***************
3ef2ca
*** 4452,4457 ****
3ef2ca
--- 4452,4463 ----
3ef2ca
      for (t = 0; t < count; ++t)
3ef2ca
      {
3ef2ca
  	curr = curr_start = ml_get((linenr_T)(curwin->w_cursor.lnum + t));
3ef2ca
+ 	if (t == 0)
3ef2ca
+ 	{
3ef2ca
+ 	    /* Set the '[ mark. */
3ef2ca
+ 	    curwin->w_buffer->b_op_start.lnum = curwin->w_cursor.lnum;
3ef2ca
+ 	    curwin->w_buffer->b_op_start.col  = (colnr_T)STRLEN(curr);
3ef2ca
+ 	}
3ef2ca
  #if defined(FEAT_COMMENTS) || defined(PROTO)
3ef2ca
  	if (remove_comments)
3ef2ca
  	{
3ef2ca
***************
3ef2ca
*** 4568,4573 ****
3ef2ca
--- 4574,4583 ----
3ef2ca
      }
3ef2ca
      ml_replace(curwin->w_cursor.lnum, newp, FALSE);
3ef2ca
  
3ef2ca
+     /* Set the '] mark. */
3ef2ca
+     curwin->w_buffer->b_op_end.lnum = curwin->w_cursor.lnum;
3ef2ca
+     curwin->w_buffer->b_op_end.col  = (colnr_T)STRLEN(newp);
3ef2ca
+ 
3ef2ca
      /* Only report the change in the first line here, del_lines() will report
3ef2ca
       * the deleted line. */
3ef2ca
      changed_lines(curwin->w_cursor.lnum, currsize,
3ef2ca
*** ../vim-7.4.177/src/version.c	2014-02-11 18:58:05.102320947 +0100
3ef2ca
--- src/version.c	2014-02-11 19:23:59.722344768 +0100
3ef2ca
***************
3ef2ca
*** 740,741 ****
3ef2ca
--- 740,743 ----
3ef2ca
  {   /* Add new patch number below this line */
3ef2ca
+ /**/
3ef2ca
+     178,
3ef2ca
  /**/
3ef2ca
3ef2ca
-- 
3ef2ca
Eight Megabytes And Continually Swapping.
3ef2ca
3ef2ca
 /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
3ef2ca
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
3ef2ca
\\\  an exciting new programming language -- http://www.Zimbu.org        ///
3ef2ca
 \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///