Commit Graph

6818 Commits

Author SHA1 Message Date
chemzqm
3cf4b14e96 add cmdline mode to modechange of RPC and tests
use set_cursor_shape_bar for cmdline mode

fix test of screen_basic_spec.lua & screen.lua

comment fix
2016-11-30 22:20:06 +08:00
Björn Linse
ecd7beb6e4 Merge pull request #5666 from bfredl/modechangetest
ui: add tests for ui_mode_change
2016-11-25 17:39:46 +01:00
Justin M. Keyes
0de6f450e4 vim-patch:7.4.2086
Problem:    Using the system default encoding makes tests unpredictable.
Solution:   Always use utf-8 or latin1 in the new style tests.  Remove setting
            encoding and scriptencoding where it is not needed.

ac105ed3c4
2016-11-25 15:46:58 +01:00
Björn Linse
4b95bb582d ui: add tests for ui_mode_change
Also fix snapshot_util() to work even if default_attr_ids is not a
proper lua array.
2016-11-25 11:37:23 +01:00
James McCoy
42736d6a2a Merge pull request #5595 from jamessan/tsan-pie
tsan: Compile with -fPIE and updated clang
2016-11-24 09:55:12 -05:00
James McCoy
cbf2a86c1d Merge pull request #5654 from brcolow/vim-7.4.1923
vim-patch:7.4.1923
2016-11-23 21:27:20 -05:00
James McCoy
2c154216a4 Merge pull request #5644 from Shougo/vim-7.4.1691
vim-patch:7.4.1691
2016-11-23 21:03:26 -05:00
James McCoy
e00bc61325 Merge pull request #5642 from Shougo/vim-7.4.1660
vim-patch:7.4.1660
2016-11-23 20:49:24 -05:00
James McCoy
b1854cefea Merge pull request #5641 from Shougo/vim-7.4.1696
vim-patch:7.4.1696
2016-11-23 20:37:37 -05:00
James McCoy
ca292c9768
Avoid serializing NULL string through msgpack
Attempting to serialize a NULL string through msgpack results in
msgpack_sbuffer_write attempting to memcpy from a NULL pointer, which is
undefined behavior.
2016-11-23 20:30:00 -05:00
James McCoy
38ee85d000
Move utf8len_tab definition to globals.h
The existing code would cause utf8len_tab to be declared as non-extern
when main.cpp included globals.h as well as in mbyte.c.  This causes the
following warning

    Linking C executable ../../bin/nvim
    /usr/bin/ld: Warning: size of symbol `utf8len_tab' changed from 256 in CMakeFiles/nvim.dir/main.c.o to 320 in CMakeFiles/nvim.dir/mbyte.c.o

Moving the definition to globals.h and using INIT() ensures the array is
only defined in main.cpp and other places globals.h is included see an
extern declaration.
2016-11-23 20:29:59 -05:00
James McCoy
6d727657c8
ci: Make ubsan print out a stacktrace when it finds a problem 2016-11-23 20:29:59 -05:00
James McCoy
b6a090b4fd
tsan: Compile with -fPIE and force clang-3.8
This fixes failures with TSAN builds like

    FATAL: ThreadSanitizer can not mmap the shadow memory (something is mapped at 0x55deea465000 < 0x7cf000000000)
    FATAL: Make sure to compile with -fPIE and to link with -pie.
2016-11-23 20:29:51 -05:00
Michael Ennen
4f8964cc00 vim-patch:7.4.1923
Problem:    Command line editing is not tested much.
Solution:   Add tests for expanding the file name and 'wildmenu'.

ae3150ec8d

The test_cmdline.vim tests were ported in 23f591dba0 and thus
should have marked 1923 as applied. The test_cmdline.vim invocation
has been moved from test_alot.vim to src/nvim/testdir/Makefile to
better accord with the upstream code.
2016-11-23 15:56:35 -07:00
Shougo Matsushita
5c06f350ce vim-patch:7.4.1691
Problem:    When switching to a new buffer and an autocommand applies syntax
            highlighting an ml_get error may occur.
Solution:   Check "syn_buf" against the buffer in the window. (Alexander von
            Buddenbrock, closes vim/vim#676)

b681be175b
2016-11-24 07:07:22 +09:00
Shougo Matsushita
81591b146a vim-patch:7.4.1696
Problem:    When using :stopinsert in a silent mapping the "INSERT" message
            isn't cleared. (Coacher)
Solution:   Always clear the message. (Christian Brabandt, closes vim/vim#718)

fd773e9e88
2016-11-24 07:04:39 +09:00
Michael Ennen
a46fc0d754 vim-patch:7.4.1928 (#5653)
Problem:    Overwriting pointer argument.
Solution:   Assign to what it points to. (Dominique Pelle)

76ae22fef3

The typos corrected in the original vim patch are no long present
in the neovim code base and the pointer assignment was done correctly
in the porting of patch 1913 (where the changes were introduced).
2016-11-23 22:00:11 +01:00
Shougo Matsushita
d152e2f3fd vim-patch:7.4.1660
Problem:    has('patch-7.4.1') doesn't work.
Solution:   Fix off-by-one error. (Thinca)

819821c5a9
2016-11-22 07:27:13 +09:00
Michael Ennen
5f0260808c build: Upgrade jemalloc from 4.2.1 to 4.3.1. (#5636)
Closes #5415
2016-11-21 13:36:55 +01:00
James McCoy
6b1c8bbc18 Merge pull request #5632 from jamessan/vim-8.0.0056
vim-patch:8.0.0056,8.0.0057
2016-11-20 23:03:24 -05:00
James McCoy
c685879eea
vim-patch:8.0.0057
Problem:    Tests fail without the 'keymap' features.
Solution:   Check for feature in test.

9376f5f482
2016-11-20 14:07:46 -05:00
James McCoy
4fad66fbe6
vim-patch:8.0.0056
Problem:    When setting 'filetype' there is no check for a valid name.
Solution:   Only allow valid characters in 'filetype', 'syntax' and 'keymap'.

d0b5138ba4
2016-11-20 14:07:46 -05:00
Justin M. Keyes
42033bc5bd Merge #5630 from nhooyr/man-ftplugin
man.vim: bug fixes
2016-11-19 22:50:10 +01:00
Anmol Sethi
7a4d069bcc
man.vim: do not assume ftplugin is sourced before syntax
Fixes #5574
2016-11-19 13:41:04 -05:00
Anmol Sethi
cf52b881d9
man.vim: no guarantee that the first line contains anything useful
Fixes #5628
2016-11-18 14:06:42 -05:00
Björn Linse
acbce46782 Merge pull request #5624 from bfredl/jobcloseterm
jobs: ensure calling jobclose() on a pty job sends SIGHUP
2016-11-17 18:40:59 +01:00
Justin M. Keyes
c3a7a94a12 l10n: Remove some non-UTF8 .po files. (#5622)
Some .po files do not have UTF8 versions, leave those alone for now.

Also remove sjiscorr.c utility.
2016-11-17 17:27:13 +01:00
Björn Linse
1d4563771b jobs: ensure calling jobclose() on a pty job sends SIGHUP. Closes #5619 2016-11-17 15:13:45 +01:00
James McCoy
927e3e32d7 Merge pull request #5623 from justinmk/luacheck
build: Target luacheck HEAD.
2016-11-16 21:17:21 -05:00
Justin M. Keyes
44e6ee930f build: Target luacheck HEAD.
https://github.com/mpeterv/luacheck/pull/81#issuecomment-261099606

> If you really want to use bleeding-edge version you should get the
> rockspec from master branch, not a fixed commit ...
> The correct way to install from a specific commit is cloning that
> commit and running "luarocks make" from project directory. The reason
> is that running "install" or "build" on an scm rockspec fetches
> sources from master but uses build description from the rockspec
> itself, which may be outdated.
2016-11-17 00:55:39 +01:00
Justin M. Keyes
5e241b5f50 build: cmake: Use portable delimiters. (#5620)
Fixes build on Windows (msys2 mingw64).
Closes #5342
2016-11-16 22:26:51 +01:00
Anatolii Sakhnik
f1fed42ca7 l10n: Update Ukrainian translation (#5567)
* Fix translation of the term 'tag'

Prefer native word instead of transliteration

* Update uk.po automatically

Run make update-po-uk in src/nvim/po

* Update fuzzy translations in uk.po

* Translate missing msgstr

* Fix layout of the front page

* Apply cleanup.vim

Additionally, remove irrelevant and confusing comments

* Copy uk.po into uk.cp1251.po
2016-11-16 18:58:07 +01:00
James McCoy
108d54bbd4 Merge pull request #5600 from jamessan/vim-7.4.1640
vim-patch:7.4.1640,7.4.1647,7.4.1650,7.4.1664
2016-11-16 06:52:19 -05:00
James McCoy
c66ca17ca1
Merge pull request #5614 from Shougo/vim-7.4.2251
vim-patch:7.4.2251
2016-11-15 23:45:20 -05:00
James McCoy
34317846d6
lint 2016-11-15 23:16:09 -05:00
James McCoy
4e66bc99e4
Mark 7.4.1697 as applied
The patch was merged in 9e1c6596 but version.c didn't get updated
accordingly.
2016-11-15 23:16:09 -05:00
James McCoy
2e5736e2cd
vim-patch:7.4.1664
Problem:    Crash in :cgetexpr.
Solution:   Check for NULL pointer. (Dominique) Add a test.

89c64d557d
2016-11-15 23:16:09 -05:00
James McCoy
830bf8665b
vim-patch:7.4.1650
Problem:    Quickfix test fails.
Solution:   Accept any number of matches.

f68f1d7079
2016-11-15 23:16:09 -05:00
James McCoy
caa33aaaf8
vim-patch:7.4.1647
Problem:    Using freed memory after setqflist() and ":caddbuffer".  (Dominique)
Solution:   Set qf_ptr when adding the first item to the quickfix list.

8b20179c65
2016-11-15 23:16:08 -05:00
James McCoy
c0fd830be4
Bump all nvim-specific error codes above E5000
In order to not conflict with new error codes that Vim adds, all Neovim
error codes should be above 5000.  The three existing sub-5000 error
codes (E926, E951, and E952) are now E50003, E5004, and E5005
respectively.

E953 was removed in 6167ce6df2, so just
remove it from the help.
2016-11-15 23:16:08 -05:00
James McCoy
7231438f12
vim-patch:7.4.1640
Problem:    Crash when an autocommand changes a quickfix list. (Dominique)
Solution:   Check wether an entry is still valid. (Yegappan Lakshmanan,
            Hirohito Higashi)

ffec3c5349
2016-11-15 23:16:08 -05:00
James McCoy
aba853a156 Merge pull request #5615 from jamessan/vim-7.4.1892
vim-patch:7.4.1892,7.4.1894
2016-11-15 22:49:34 -05:00
James McCoy
49f73e5275
vim-patch:7.4.1894
Problem:    Cannot get the window ID for a mouse click.
Solution:   Add v:mouse_winid.

511972d810
2016-11-15 22:00:25 -05:00
James McCoy
defa86b08a
vim-patch:7.4.1892
Problem:    balloon eval only gets the window number, not the ID.
Solution:   Add v:beval_winid.

c9721bdc63
2016-11-15 21:48:08 -05:00
Shougo Matsushita
458b1fc0e7 vim-patch:7.4.2251
Problem:    In rare cases diffing 4 buffers is not enough.
Solution:   Raise the limit to 8. (closes vim/vim#1000)

015efc32c1
2016-11-16 08:55:17 +09:00
James McCoy
c91e9c1c7a Merge pull request #5611 from jamessan/vim-7.4.2174
vim-patch:7.4.2174
2016-11-15 14:57:57 -05:00
Shougo
c69cfd7d1c vim-patch:8.0.0035 (#5609)
Problem:    Order of matches for 'omnifunc' is messed up. (Danny Su)
Solution:   Do not set compl_curr_match when called from complete_check().
            (closes vim/vim#1168)

472e85970e
2016-11-15 17:59:55 +01:00
James McCoy
12ed735719 lint 2016-11-15 11:50:54 -05:00
James McCoy
9d9d93aee3 vim-patch:7.4.2174
Problem:    Adding duplicate flags to 'whichwrap' leaves commas behind.
Solution:   Also remove the commas. (Naruhiko Nishino)

c8ce615299
2016-11-15 11:48:37 -05:00
James McCoy
10c72cd365
vim-patch.sh: Remove "set -o pipefail"
grep 2.26 changed its behavior when redirecting its output to /dev/null
such that it exits as soon as one match is found.  This causes sed to
get a SIGPIPE which, due to "set -o pipefail", falsely implies that the
patch is not applied.

Removing "set -o pipefail" preserves the good exit status from grep.
2016-11-15 07:53:01 -05:00