Skip to content

Commit a311d0d

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents 7b046c0 + a4c906a commit a311d0d

24 files changed

+1217
-493
lines changed

src/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2164,6 +2164,7 @@ test_arglist \
21642164
test_langmap \
21652165
test_largefile \
21662166
test_lispwords \
2167+
test_lua \
21672168
test_man \
21682169
test_mapping \
21692170
test_marks \
@@ -2185,6 +2186,8 @@ test_arglist \
21852186
test_popup \
21862187
test_profile \
21872188
test_put \
2189+
test_python2 \
2190+
test_python3 \
21882191
test_pyx2 \
21892192
test_pyx3 \
21902193
test_quickfix \
@@ -2212,6 +2215,7 @@ test_arglist \
22122215
test_tabpage \
22132216
test_tagcase \
22142217
test_tagjump \
2218+
test_tcl \
22152219
test_textobjects \
22162220
test_timers \
22172221
test_true_false \

src/edit.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6180,6 +6180,9 @@ insertchar(
61806180
&& (!has_mbyte || MB_BYTE2LEN_CHECK(c) == 1)
61816181
#endif
61826182
&& i < INPUT_BUFLEN
6183+
# ifdef FEAT_FKMAP
6184+
&& !(p_fkmap && KeyTyped) /* Farsi mode mapping moves cursor */
6185+
# endif
61836186
&& (textwidth == 0
61846187
|| (virtcol += byte2cells(buf[i - 1])) < (colnr_T)textwidth)
61856188
&& !(!no_abbr && !vim_iswordc(c) && vim_iswordc(buf[i - 1])))
@@ -6188,10 +6191,6 @@ insertchar(
61886191
c = vgetc();
61896192
if (p_hkmap && KeyTyped)
61906193
c = hkmap(c); /* Hebrew mode mapping */
6191-
# ifdef FEAT_FKMAP
6192-
if (p_fkmap && KeyTyped)
6193-
c = fkmap(c); /* Farsi mode mapping */
6194-
# endif
61956194
buf[i++] = c;
61966195
#else
61976196
buf[i++] = vgetc();

src/evalfunc.c

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2819,7 +2819,17 @@ f_execute(typval_T *argvars, typval_T *rettv)
28192819
--list->lv_refcount;
28202820
}
28212821

2822-
rettv->vval.v_string = redir_execute_ga.ga_data;
2822+
/* Need to append a NUL to the result. */
2823+
if (ga_grow(&redir_execute_ga, 1) == OK)
2824+
{
2825+
((char *)redir_execute_ga.ga_data)[redir_execute_ga.ga_len] = NUL;
2826+
rettv->vval.v_string = redir_execute_ga.ga_data;
2827+
}
2828+
else
2829+
{
2830+
ga_clear(&redir_execute_ga);
2831+
rettv->vval.v_string = NULL;
2832+
}
28232833
msg_silent = save_msg_silent;
28242834
emsg_silent = save_emsg_silent;
28252835
emsg_noredir = save_emsg_noredir;

src/ex_cmds.h

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,8 @@
6565
#define ADDR_LOADED_BUFFERS 3
6666
#define ADDR_BUFFERS 4
6767
#define ADDR_TABS 5
68-
#define ADDR_QUICKFIX 6
68+
#define ADDR_TABS_RELATIVE 6 /* Tab page that only relative */
69+
#define ADDR_QUICKFIX 7
6970
#define ADDR_OTHER 99
7071

7172
#ifndef DO_DECLARE_EXCMD
@@ -1431,9 +1432,9 @@ EX(CMD_tags, "tags", do_tags,
14311432
ADDR_LINES),
14321433
EX(CMD_tab, "tab", ex_wrongmodifier,
14331434
NEEDARG|EXTRA|NOTRLCOM,
1434-
ADDR_LINES),
1435+
ADDR_TABS),
14351436
EX(CMD_tabclose, "tabclose", ex_tabclose,
1436-
RANGE|NOTADR|COUNT|BANG|TRLBAR|CMDWIN,
1437+
BANG|RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR|CMDWIN,
14371438
ADDR_TABS),
14381439
EX(CMD_tabdo, "tabdo", ex_listdo,
14391440
NEEDARG|EXTRA|NOTRLCOM|RANGE|NOTADR|DFLALL,
@@ -1446,34 +1447,34 @@ EX(CMD_tabfind, "tabfind", ex_splitview,
14461447
ADDR_TABS),
14471448
EX(CMD_tabfirst, "tabfirst", ex_tabnext,
14481449
TRLBAR,
1449-
ADDR_LINES),
1450+
ADDR_TABS),
14501451
EX(CMD_tabmove, "tabmove", ex_tabmove,
14511452
RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR,
14521453
ADDR_TABS),
14531454
EX(CMD_tablast, "tablast", ex_tabnext,
14541455
TRLBAR,
1455-
ADDR_LINES),
1456+
ADDR_TABS),
14561457
EX(CMD_tabnext, "tabnext", ex_tabnext,
1457-
RANGE|NOTADR|COUNT|TRLBAR,
1458-
ADDR_LINES),
1458+
RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR,
1459+
ADDR_TABS),
14591460
EX(CMD_tabnew, "tabnew", ex_splitview,
14601461
BANG|FILE1|RANGE|NOTADR|ZEROR|EDITCMD|ARGOPT|TRLBAR,
14611462
ADDR_TABS),
14621463
EX(CMD_tabonly, "tabonly", ex_tabonly,
1463-
BANG|RANGE|NOTADR|TRLBAR|CMDWIN,
1464+
BANG|RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR|CMDWIN,
14641465
ADDR_TABS),
14651466
EX(CMD_tabprevious, "tabprevious", ex_tabnext,
1466-
RANGE|NOTADR|COUNT|TRLBAR,
1467-
ADDR_LINES),
1467+
RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR,
1468+
ADDR_TABS_RELATIVE),
14681469
EX(CMD_tabNext, "tabNext", ex_tabnext,
1469-
RANGE|NOTADR|COUNT|TRLBAR,
1470-
ADDR_LINES),
1470+
RANGE|NOTADR|ZEROR|EXTRA|NOSPC|TRLBAR,
1471+
ADDR_TABS_RELATIVE),
14711472
EX(CMD_tabrewind, "tabrewind", ex_tabnext,
14721473
TRLBAR,
1473-
ADDR_LINES),
1474+
ADDR_TABS),
14741475
EX(CMD_tabs, "tabs", ex_tabs,
14751476
TRLBAR|CMDWIN,
1476-
ADDR_LINES),
1477+
ADDR_TABS),
14771478
EX(CMD_tcl, "tcl", ex_tcl,
14781479
RANGE|EXTRA|NEEDARG|CMDWIN,
14791480
ADDR_LINES),

0 commit comments

Comments
 (0)