Skip to content

Commit a5660a2

Browse files
committed
Merge remote-tracking branch 'vim/master'
2 parents b3d9e6e + 75be233 commit a5660a2

44 files changed

Lines changed: 2124 additions & 644 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

runtime/doc/eval.txt

Lines changed: 320 additions & 302 deletions
Large diffs are not rendered by default.

runtime/doc/if_pyth.txt

Lines changed: 24 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -653,10 +653,25 @@ vim.List object *python-List*
653653
class List(vim.List): # Subclassing
654654
655655
vim.Function object *python-Function*
656-
Function-like object, acting like vim |Funcref| object. Supports `.name`
657-
attribute and is callable. Accepts special keyword argument `self`, see
658-
|Dictionary-function|. You can also use `vim.Function(name)` constructor,
659-
it is the same as `vim.bindeval('function(%s)'%json.dumps(name))`.
656+
Function-like object, acting like vim |Funcref| object. Accepts special
657+
keyword argument `self`, see |Dictionary-function|. You can also use
658+
`vim.Function(name)` constructor, it is the same as
659+
`vim.bindeval('function(%s)'%json.dumps(name))`.
660+
661+
Attributes (read-only):
662+
Attribute Description ~
663+
name Function name.
664+
args `None` or a |python-List| object with arguments. Note that
665+
this is a copy of the arguments list, constructed each time
666+
you request this attribute. Modifications made to the list
667+
will be ignored (but not to the containers inside argument
668+
list: this is like |copy()| and not |deepcopy()|).
669+
self `None` or a |python-Dictionary| object with self
670+
dictionary. Note that explicit `self` keyword used when
671+
calling resulting object overrides this attribute.
672+
673+
Constructor additionally accepts `args` and `self` keywords. If any of
674+
them is given then it constructs a partial, see |function()|.
660675

661676
Examples: >
662677
f = vim.Function('tr') # Constructor
@@ -670,6 +685,11 @@ vim.Function object *python-Function*
670685
print f(self={}) # Like call('DictFun', [], {})
671686
print isinstance(f, vim.Function) # True
672687
688+
p = vim.Function('DictFun', self={})
689+
print f()
690+
p = vim.Function('tr', args=['abc', 'a'])
691+
print f('b')
692+
673693
==============================================================================
674694
8. pyeval() and py3eval() Vim functions *python-pyeval*
675695

runtime/doc/message.txt

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
*message.txt* For Vim version 7.4. Last change: 2016 Feb 27
1+
*message.txt* For Vim version 7.4. Last change: 2016 Apr 14
22

33

44
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -19,6 +19,15 @@ The ":messages" command can be used to view previously given messages. This
1919
is especially useful when messages have been overwritten or truncated. This
2020
depends on the 'shortmess' option.
2121

22+
:messages Show all messages.
23+
24+
:{count}messages Show the {count} most recent messages.
25+
26+
:messages clear Clear all messages.
27+
28+
:{count}messages clear Clear messages, keeping only the {count} most
29+
recent ones.
30+
2231
The number of remembered messages is fixed at 20 for the tiny version and 200
2332
for other versions.
2433

@@ -58,8 +67,9 @@ If you are lazy, it also works without the shift key: >
5867
When an error message is displayed, but it is removed before you could read
5968
it, you can see it again with: >
6069
:echo errmsg
61-
or view a list of recent messages with: >
70+
Or view a list of recent messages with: >
6271
:messages
72+
See `:messages` above.
6373

6474

6575
LIST OF MESSAGES

src/Makefile

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2015,23 +2015,25 @@ test1 \
20152015
test70 test71 test72 test73 test74 test75 test76 test77 test78 test79 \
20162016
test80 test81 test82 test83 test84 test85 test86 test87 test88 test89 \
20172017
test90 test91 test92 test93 test94 test95 test97 test98 test99 \
2018-
test100 test101 test102 test103 test104 test105 test107 test108:
2018+
test100 test101 test102 test103 test104 test107 test108:
20192019
cd testdir; rm -f [email protected]; $(MAKE) -f Makefile [email protected] VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
20202020

20212021
# Run individual NEW style test, assuming that Vim was already compiled.
20222022
test_arglist \
20232023
test_assert \
20242024
test_assign \
2025+
test_autocmd \
20252026
test_backspace_opt \
20262027
test_cdo \
20272028
test_channel \
20282029
test_cursor_func \
20292030
test_delete \
20302031
test_ex_undo \
2031-
test_expr \
20322032
test_expand \
2033+
test_expr \
20332034
test_feedkeys \
20342035
test_file_perm \
2036+
test_fnamemodify \
20352037
test_glob2regpat \
20362038
test_hardcopy \
20372039
test_help_tagjump \
@@ -2041,24 +2043,31 @@ test_arglist \
20412043
test_json \
20422044
test_langmap \
20432045
test_lispwords \
2046+
test_matchstrpos \
20442047
test_menu \
20452048
test_packadd \
20462049
test_partial \
20472050
test_perl \
20482051
test_quickfix \
2052+
test_regexp_latin \
2053+
test_regexp_utf8 \
20492054
test_reltime \
20502055
test_searchpos \
20512056
test_set \
20522057
test_sort \
2058+
test_statusline \
20532059
test_syn_attr \
20542060
test_syntax \
2061+
test_tabline \
20552062
test_timers \
20562063
test_undolevels \
20572064
test_unlet \
20582065
test_viminfo \
20592066
test_viml \
20602067
test_visual \
20612068
test_window_id \
2069+
test_alot_latin \
2070+
test_alot_utf8 \
20622071
test_alot:
20632072
cd testdir; rm -f [email protected] test.log messages; $(MAKE) -f Makefile [email protected] VIMPROG=../$(VIMTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
20642073
@if test -f testdir/test.log; then \
@@ -2143,9 +2152,11 @@ installrtbase: $(HELPSOURCE)/vim.1 $(DEST_VIM) $(DEST_RT) \
21432152
# Generate the help tags with ":helptags" to handle all languages.
21442153
# Move the distributed tags file aside and restore it, to avoid it being
21452154
# different from the repository.
2146-
cd $(HELPSOURCE); if test -f tags; then mv -f tags tags.dist; fi
2155+
cd $(HELPSOURCE); if test -z "$(CROSS_COMPILING)" -a -f tags; then \
2156+
mv -f tags tags.dist; fi
21472157
@echo generating help tags
2148-
-@cd $(HELPSOURCE); $(MAKE) VIMEXE=$(DEST_BIN)/$(VIMTARGET) vimtags
2158+
-@cd $(HELPSOURCE); if test -z "$(CROSS_COMPILING)"; then \
2159+
$(MAKE) VIMEXE=$(DEST_BIN)/$(VIMTARGET) vimtags; fi
21492160
cd $(HELPSOURCE); \
21502161
files=`ls *.txt tags`; \
21512162
files="$$files `ls *.??x tags-?? 2>/dev/null || true`"; \

src/auto/configure

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -723,6 +723,7 @@ OS_EXTRA_OBJ
723723
OS_EXTRA_SRC
724724
XCODE_SELECT
725725
CPP_MM
726+
CROSS_COMPILING
726727
STRIP
727728
AWK
728729
FGREP
@@ -4123,11 +4124,14 @@ else
41234124
$as_echo "no" >&6; }
41244125
fi
41254126

4127+
CROSS_COMPILING=
41264128
if test "$cross_compiling" = yes; then
41274129
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot compile a simple program; if not cross compiling check CC and CFLAGS" >&5
41284130
$as_echo "cannot compile a simple program; if not cross compiling check CC and CFLAGS" >&6; }
4131+
CROSS_COMPILING=1
41294132
fi
41304133

4134+
41314135
test "$GCC" = yes && CPP_MM=M;
41324136

41334137
if test -f ./toolcheck; then

src/channel.c

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -461,8 +461,7 @@ free_unused_channels(int copyID, int mask)
461461
ch_next = ch->ch_next;
462462
if ((ch->ch_copyID & mask) != (copyID & mask))
463463
{
464-
/* Free the channel and ordinary items it contains, but don't
465-
* recurse into Lists, Dictionaries etc. */
464+
/* Free the channel struct itself. */
466465
channel_free_channel(ch);
467466
}
468467
}
@@ -4025,15 +4024,25 @@ job_free(job_T *job)
40254024
}
40264025
}
40274026

4027+
/*
4028+
* Return TRUE if the job should not be freed yet. Do not free the job when
4029+
* it has not ended yet and there is a "stoponexit" flag or an exit callback.
4030+
*/
4031+
static int
4032+
job_still_useful(job_T *job)
4033+
{
4034+
return job->jv_status == JOB_STARTED
4035+
&& (job->jv_stoponexit != NULL || job->jv_exit_cb != NULL);
4036+
}
4037+
40284038
void
40294039
job_unref(job_T *job)
40304040
{
40314041
if (job != NULL && --job->jv_refcount <= 0)
40324042
{
40334043
/* Do not free the job when it has not ended yet and there is a
40344044
* "stoponexit" flag or an exit callback. */
4035-
if (job->jv_status != JOB_STARTED
4036-
|| (job->jv_stoponexit == NULL && job->jv_exit_cb == NULL))
4045+
if (!job_still_useful(job))
40374046
{
40384047
job_free(job);
40394048
}
@@ -4055,7 +4064,8 @@ free_unused_jobs_contents(int copyID, int mask)
40554064
job_T *job;
40564065

40574066
for (job = first_job; job != NULL; job = job->jv_next)
4058-
if ((job->jv_copyID & mask) != (copyID & mask))
4067+
if ((job->jv_copyID & mask) != (copyID & mask)
4068+
&& !job_still_useful(job))
40594069
{
40604070
/* Free the channel and ordinary items it contains, but don't
40614071
* recurse into Lists, Dictionaries etc. */
@@ -4074,10 +4084,10 @@ free_unused_jobs(int copyID, int mask)
40744084
for (job = first_job; job != NULL; job = job_next)
40754085
{
40764086
job_next = job->jv_next;
4077-
if ((job->jv_copyID & mask) != (copyID & mask))
4087+
if ((job->jv_copyID & mask) != (copyID & mask)
4088+
&& !job_still_useful(job))
40784089
{
4079-
/* Free the channel and ordinary items it contains, but don't
4080-
* recurse into Lists, Dictionaries etc. */
4090+
/* Free the job struct itself. */
40814091
job_free_job(job);
40824092
}
40834093
}

src/config.mk.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,7 @@ AWK = @AWK@
106106
STRIP = @STRIP@
107107

108108
EXEEXT = @EXEEXT@
109+
CROSS_COMPILING = @CROSS_COMPILING@
109110

110111
COMPILEDBY = @compiledby@
111112

src/configure.in

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,12 @@ fi
8888

8989
dnl If configure thinks we are cross compiling, there might be something
9090
dnl wrong with the CC or CFLAGS settings, give a useful warning message
91+
CROSS_COMPILING=
9192
if test "$cross_compiling" = yes; then
9293
AC_MSG_RESULT([cannot compile a simple program; if not cross compiling check CC and CFLAGS])
94+
CROSS_COMPILING=1
9395
fi
96+
AC_SUBST(CROSS_COMPILING)
9497

9598
dnl gcc-cpp has the wonderful -MM option to produce nicer dependencies.
9699
dnl But gcc 3.1 changed the meaning! See near the end.

src/edit.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1433,8 +1433,10 @@ edit(
14331433

14341434
docomplete:
14351435
compl_busy = TRUE;
1436+
disable_fold_update++; /* don't redraw folds here */
14361437
if (ins_complete(c, TRUE) == FAIL)
14371438
compl_cont_status = 0;
1439+
disable_fold_update--;
14381440
compl_busy = FALSE;
14391441
break;
14401442
#endif /* FEAT_INS_EXPAND */

0 commit comments

Comments
 (0)