mirror of
https://github.com/vim/vim.git
synced 2025-09-30 04:44:14 -04:00
updated for version 7.4.490
Problem: Cannot specify the buffer to use for "do" and "dp", making them useless for three-way diff. Solution: Use the count as the buffer number. (James McCoy)
This commit is contained in:
10
src/diff.c
10
src/diff.c
@@ -2107,12 +2107,20 @@ diff_infold(wp, lnum)
|
|||||||
* "dp" and "do" commands.
|
* "dp" and "do" commands.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
nv_diffgetput(put)
|
nv_diffgetput(put, count)
|
||||||
int put;
|
int put;
|
||||||
|
long count;
|
||||||
{
|
{
|
||||||
exarg_T ea;
|
exarg_T ea;
|
||||||
|
char_u buf[30];
|
||||||
|
|
||||||
|
if (count == 0)
|
||||||
ea.arg = (char_u *)"";
|
ea.arg = (char_u *)"";
|
||||||
|
else
|
||||||
|
{
|
||||||
|
vim_snprintf((char *)buf, 30, "%ld", count);
|
||||||
|
ea.arg = buf;
|
||||||
|
}
|
||||||
if (put)
|
if (put)
|
||||||
ea.cmdidx = CMD_diffput;
|
ea.cmdidx = CMD_diffput;
|
||||||
else
|
else
|
||||||
|
@@ -9284,7 +9284,7 @@ nv_put(cap)
|
|||||||
if (cap->oap->op_type == OP_DELETE && cap->cmdchar == 'p')
|
if (cap->oap->op_type == OP_DELETE && cap->cmdchar == 'p')
|
||||||
{
|
{
|
||||||
clearop(cap->oap);
|
clearop(cap->oap);
|
||||||
nv_diffgetput(TRUE);
|
nv_diffgetput(TRUE, cap->opcount);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
@@ -9407,7 +9407,7 @@ nv_open(cap)
|
|||||||
if (cap->oap->op_type == OP_DELETE && cap->cmdchar == 'o')
|
if (cap->oap->op_type == OP_DELETE && cap->cmdchar == 'o')
|
||||||
{
|
{
|
||||||
clearop(cap->oap);
|
clearop(cap->oap);
|
||||||
nv_diffgetput(FALSE);
|
nv_diffgetput(FALSE, cap->opcount);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
|
@@ -18,7 +18,7 @@ int diffopt_changed __ARGS((void));
|
|||||||
int diffopt_horizontal __ARGS((void));
|
int diffopt_horizontal __ARGS((void));
|
||||||
int diff_find_change __ARGS((win_T *wp, linenr_T lnum, int *startp, int *endp));
|
int diff_find_change __ARGS((win_T *wp, linenr_T lnum, int *startp, int *endp));
|
||||||
int diff_infold __ARGS((win_T *wp, linenr_T lnum));
|
int diff_infold __ARGS((win_T *wp, linenr_T lnum));
|
||||||
void nv_diffgetput __ARGS((int put));
|
void nv_diffgetput __ARGS((int put, long count));
|
||||||
void ex_diffgetput __ARGS((exarg_T *eap));
|
void ex_diffgetput __ARGS((exarg_T *eap));
|
||||||
int diff_mode_buf __ARGS((buf_T *buf));
|
int diff_mode_buf __ARGS((buf_T *buf));
|
||||||
int diff_move_to __ARGS((int dir, long count));
|
int diff_move_to __ARGS((int dir, long count));
|
||||||
|
@@ -741,6 +741,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
490,
|
||||||
/**/
|
/**/
|
||||||
489,
|
489,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user