File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2851,9 +2851,17 @@ findpar(
28512851 curwin -> w_cursor .lnum = curr ;
28522852 if (curr == curbuf -> b_ml .ml_line_count && what != '}' )
28532853 {
2854- if ((curwin -> w_cursor .col = (colnr_T )STRLEN (ml_get (curr ))) != 0 )
2854+ char_u * line = ml_get (curr );
2855+
2856+ /* Put the cursor on the last character in the last line and make the
2857+ * motion inclusive. */
2858+ if ((curwin -> w_cursor .col = (colnr_T )STRLEN (line )) != 0 )
28552859 {
28562860 -- curwin -> w_cursor .col ;
2861+ #ifdef FEAT_MBYTE
2862+ curwin -> w_cursor .col -=
2863+ (* mb_head_off )(line , line + curwin -> w_cursor .col );
2864+ #endif
28572865 * pincl = TRUE;
28582866 }
28592867 }
Original file line number Diff line number Diff line change @@ -2290,3 +2290,15 @@ func Test_normal_large_count()
22902290 normal 6666666666 dL
22912291 bwipe!
22922292endfunc
2293+
2294+ func Test_delete_until_paragraph ()
2295+ if ! has (' multi_byte' )
2296+ return
2297+ endif
2298+ new
2299+ normal gr ádv}
2300+ call assert_equal (' á' , getline (1 ))
2301+ normal gr ád }
2302+ call assert_equal (' ' , getline (1 ))
2303+ bwipe!
2304+ endfunc
Original file line number Diff line number Diff line change @@ -764,6 +764,8 @@ static char *(features[]) =
764764
765765static int included_patches [] =
766766{ /* Add new patch number below this line */
767+ /**/
768+ 523 ,
767769/**/
768770 522 ,
769771/**/
You can’t perform that action at this time.
0 commit comments