Commit Graph

16215 Commits

Author SHA1 Message Date
Jan Edmund Lazo
9abfb85264
vim-patch:8.2.1360: stray error for white space after expression
Problem:    Stray error for white space after expression.
Solution:   Ignore trailing white space. (closes vim/vim#6608)
f96e9dec63
2020-08-14 18:20:28 -04:00
Jan Edmund Lazo
7a047d8dc2
vim-patch:8.2.1347: cannot easily get the script ID
Problem:    Cannot easily get the script ID.
Solution:   Support expand('<SID>').
909443028b
2020-08-14 18:20:28 -04:00
Jan Edmund Lazo
0680b5218e
vim-patch:8.1.2341: not so easy to interrupt a script programatically
Problem:    Not so easy to interrupt a script programatically.
Solution:   Add the interrupt() function. (Yasuhiro Matsumoto, closes vim/vim#2834)
67a2deb9cb
2020-08-14 18:20:28 -04:00
Jan Edmund Lazo
6d68b2801b
vim-patch:8.1.1674: script to check a colorscheme can be improved
Problem:    Script to check a colorscheme can be improved.
Solution:   Match the whole group name. Don't warn for what is usually omitted.
4e63f9425e
2020-08-14 18:20:27 -04:00
Jan Edmund Lazo
903cd73af1
vim-patch:8.1.0573: cannot redefine user command without ! in same script
Problem:    Cannot redefine user command without ! in same script
Solution:   Allow redefining user command without ! in same script, like with
            functions.
55d4691308
2020-08-14 18:20:27 -04:00
TJ DeVries
3ccdbc570d
lua: add vim.register_keystroke_callback (#12536)
* feat: Add vim.register_keystroke_callback

* fixup: Forgot to remove mention of old option

* fixup: Answer jamessan comments

* fixup: Answer norcalli comments

* fixup: portability

* Update runtime/doc/lua.txt

Co-authored-by: Ashkan Kiani <ashkan.k.kiani@gmail.com>
2020-08-14 10:03:17 -04:00
TJ DeVries
aa48c1c724
Merge pull request #12739 from vigoux/ts-refactor-predicates
treesitter: refactor
2020-08-14 08:33:50 -04:00
Thomas Vigouroux
6a8dcfab4b treesitter: allow to force predicate addition 2020-08-13 20:40:40 +02:00
Thomas Vigouroux
5900c99b7c treesitter: update docs on predicates 2020-08-13 20:30:15 +02:00
Thomas Vigouroux
9564803d1a treesitter: add predicate negation 2020-08-13 20:30:15 +02:00
Thomas Vigouroux
d7b12e58df treesitter: add and test vim-match? predicate 2020-08-13 20:30:15 +02:00
Thomas Vigouroux
58e37d7df8 treesitter: add contains? predicate 2020-08-13 20:30:15 +02:00
Thomas Vigouroux
18c0e77528 treesitter(docs): update and refresh docs 2020-08-13 20:30:15 +02:00
Thomas Vigouroux
613068071e treesitter: refactor and use lua regexes 2020-08-13 20:30:15 +02:00
James McCoy
94b7ff730a
Merge pull request #12731 from jamessan/libcallnr
libcall: Use "int" for number argument
2020-08-10 23:23:54 -04:00
James McCoy
272389da32
Merge pull request #12632 from tjdevries/tjdevries/packadd_lua
[RFC] lua: Force update of rtp more often
2020-08-10 19:30:58 -04:00
TJ DeVries
e797d0658c fix: runtimepath always updates lua package.path 2020-08-10 16:48:35 -04:00
Matthieu Coudron
602e7505e2
Merge pull request #12621 from Shougo/vim-8.1.1564
[RDY] vim-patch:8.1.1564, 1570, 1623, 1712 : sign column takes up space
2020-08-09 16:19:11 +02:00
Patrice Peterson
1869f86e35
Remove unused function (#12719) 2020-08-08 23:49:44 +02:00
Anmol Sethi
7f49594813
man.vim: Add - to 'iskeyword' (#12598)
Pressing K on manpages with - in their name will now work.

I noticed this the manpages of https://github.com/cli/cli
2020-08-08 12:48:33 -04:00
James McCoy
840c12c107
Merge remote-tracking branch 'upstream/master' into libcallnr 2020-08-08 08:57:35 -04:00
James McCoy
e813ec79c2
libcall: Use "int" for number argument
The libcall family of functions need to use "int" for both input and
output.  The output side was fixed in 9c42232 but I forgot about the
input side.
# Please enter the commit message for your changes. Lines starting
# with '#' will be ignored, and an empty message aborts the commit.
#
# On branch libcallnr
# Your branch is up to date with 'upstream/master'.
#
# Changes to be committed:
#	modified:   src/nvim/eval/funcs.c
#	modified:   src/nvim/os/dl.c
#
2020-08-08 08:53:35 -04:00
erw7
f26df8bb66
Merge pull request #12701 from erw7/fix-sattr-t-overflow
ui: fix problem with sattr_T overflow
2020-08-03 22:57:13 +09:00
Matthieu Coudron
4ed5204bc9
Merge pull request #12665 from janlazo/vim-8.2.1254
vim-patch:8.0.1774,8.1.{192,194,255,264,1202,2172,2340},8.2.{62,71,72,1004,1254,1259,1265,1267,1292,1295}
2020-08-02 20:19:48 +02:00
Jan Edmund Lazo
ea515f8ca1
vim-patch:8.1.0264: backup tests fail when CWD is in /tmp
Problem:    Backup tests fail when CWD is in /tmp.
Solution:   Make 'backupskip' empty. (Christian Brabandt, closes vim/vim#3301)
efe03738f6
2020-08-02 12:00:03 -04:00
Jan Edmund Lazo
ae92177063
vim-patch:8.1.0255: backup test fails when using shadow directory
Problem:    Backup test fails when using shadow directory.
Solution:   Remove check for "src".
f8f88f89e1
2020-08-02 12:00:03 -04:00
Jan Edmund Lazo
0d713fc8ba
options: fix 'isident' for Windows
Default value on Windows does not match the documented value.
2020-08-02 12:00:02 -04:00
Jan Edmund Lazo
1123a979d0
vim-patch:8.1.0862: no verbose version of character classes
Problem:    No verbose version of character classes.
Solution:   Add [:ident:], [:keyword:] and [:fname:]. (Ozaki Kiichi,
            closes vim/vim#1373)
221cd9f4dd
2020-08-02 12:00:02 -04:00
Jan Edmund Lazo
0393eec3ea
tests/terminal/tui: wait 1ms to avoid data race in FreeBSD 2020-08-02 12:00:02 -04:00
Jan Edmund Lazo
513d117947
vim-patch:8.2.1295: tests 44 and 99 are old style
Problem:    Tests 44 and 99 are old style.
Solution:   Convert to new style tests. (Yegappan Lakshmanan, closes vim/vim#6536)
7d40b8a532
2020-08-02 12:00:02 -04:00
Jan Edmund Lazo
45b91711e4
vim-patch:8.2.1292: AIDL filetype not recognized
Problem:    AIDL filetype not recognized.
Solution:   Add filetype detection. (Dominique Pellé, closes vim/vim#6533)
2afc3b4f77
2020-08-02 12:00:02 -04:00
Jan Edmund Lazo
6f3a18197b
vim-patch:8.1.2340: quickfix test fails under valgrind and asan
Problem:    Quickfix test fails under valgrind and asan.
Solution:   Make sure long line does not overflow IObuff. (Dominique Pelle,
            closes vim/vim#5263)  Put back fix for large terminals. (Yegappan
            Lakshmanan, closes vim/vim#5264)
a106e6cde6
2020-08-02 12:00:02 -04:00
Jan Edmund Lazo
886969e1f8
vim-patch:8.1.1202: always get regexp debugging logs when building with -DDEBUG
Problem:    Always get regexp debugging logs when building with -DDEBUG.
Solution:   By default do not create regexp debugging logs. (Ken Takata)
c2d09c9f2c
2020-08-02 12:00:01 -04:00
Jan Edmund Lazo
ca698250fc
vim-patch:8.1.0194: possibly use of NULL pointer
Problem:    Possibly use of NULL pointer. (Coverity)
Solution:   Reset the re_in_use flag earlier.
414998023f
2020-08-02 12:00:01 -04:00
Jan Edmund Lazo
1ab1de7845
vim-patch:8.1.0192: executing regexp recursively fails with a crash
Problem:    Executing regexp recursively fails with a crash.
Solution:   Move global variables into "rex".
0270f38e1a
2020-08-02 12:00:01 -04:00
Jan Edmund Lazo
f3964c170e
vim-patch:8.2.1267: MS-Windows: tests may fail due to $PROMPT value
Problem:    MS-Windows: tests may fail due to $PROMPT value.
Solution:   Set $PROMPT for testing. (Taro Muraoka, closes vim/vim#6510)
2690b5aed8
2020-08-02 12:00:01 -04:00
Jan Edmund Lazo
2d34ddb3c3
vim-patch:8.2.1265: crash with EXITFREE when split() fails
Problem:    Crash with EXITFREE when split() fails.
Solution:   Restore 'cpoptions'.
7d5e744162
2020-08-02 12:00:01 -04:00
Jan Edmund Lazo
9443d39941
vim-patch:8.2.1259: empty group in 'tabline' may cause using an invalid pointer
Problem:    Empty group in 'tabline' may cause using an invalid pointer.
Solution:   Set the group start position. (closes vim/vim#6505)
f56c95fdad
2020-08-02 12:00:00 -04:00
Jan Edmund Lazo
ed41ac08cf
vim-patch:8.2.1004: line numbers below filler lines not always updated
Problem:    Line numbers below filler lines not always updated.
Solution:   Don't break out of the win_line() loop too early. (Christian
            Brabandt, closes vim/vim#6294, closes vim/vim#6138)
511feec6f0
2020-08-02 12:00:00 -04:00
Jan Edmund Lazo
1e6bf6f17a
vim-patch:8.2.0072: memory test still fails on Cirrus CI
Problem:    Memory test still fails on Cirrus CI.
Solution:   Allow for a tiny bit more tolerance in the upper limit.
bb062c1588

Check memory usage after  Neovim sourced the Vimscript files.
https://github.com/neovim/neovim/pull/12679

N/A patches for version.c:

vim-patch:8.2.0062: memory test is flaky on FreeBSD

Problem:    Memory test is flaky on FreeBSD.
Solution:   Add a short sleep before getting the first size.
e7538ae997

vim-patch:8.2.0071: memory test often fails on Cirrus CI

Problem:    Memory test often fails on Cirrus CI.
Solution:   Allow for more tolerance in the upper limit.  Remove sleep.
1832d12aea
2020-08-02 12:00:00 -04:00
Jan Edmund Lazo
c207886bdf
vim-patch:8.1.2172: spell highlight is wrong at start of the line
Problem:    Spell highlight is wrong at start of the line.
Solution:   Fix setting the "v" variable. (closes vim/vim#5078)
7751d1d1a3

Skip spell tests in OpenBSD.

Nvim or screen likely crashed.
Revist once issue #12104 is fixed.
Skip the test for the following reasons:
- unknown regression caused by https://github.com/neovim/neovim/issues/12104
- cannot revert failing test from ed0d135247
2020-08-02 12:00:00 -04:00
Jan Edmund Lazo
521d571992
vim-patch:8.0.1774: reading very long lines can be slow
Problem:    Reading very long lines can be slow.
Solution:   Read up to 1 Mbyte at a time to avoid a lot of copying.  Add a
            check for going over the column limit.
13d3b05ed2
2020-08-02 12:00:00 -04:00
Jan Edmund Lazo
55ff49b1a7
vim-patch:8.2.1254: MS-Windows: regexp test may fail if 'iskeyword' set wrongly
Problem:    MS-Windows: regexp test may fail if 'iskeyword' set wrongly.
Solution:   Override the 'iskeyword' value. (Taro Muraoka, closes vim/vim#6502)
470adb827f
2020-08-02 11:59:59 -04:00
James McCoy
480515e442
Merge pull request #12700 from jamessan/fileinfo-garbage 2020-08-02 11:27:12 -04:00
erw7
872ecf65d1 ui: fix problem with sattr_T overflow
sattr_T was defined as uint16_t. But this is not enough to handle the
24-bit colors of the terminal. To solve this problem, change it to int.
In 32bit, int may overflow. So, if it overflows, change it to ignore it
without adding more attr_entries.

fixes #12366
2020-08-02 22:33:18 +09:00
James McCoy
228d7d9482
Merge remote-tracking branch 'upstream/master' into fileinfo-garbage 2020-07-31 17:59:48 -04:00
James McCoy
3e3002b90c
fs: Ensure FileInfo struct is initialized
Zero out the caller's FileInfo in all the functions which populate the
struct.  The contents are considered private, so we need to ensure
it's initialized.

If the stat call fails, the buffer we get back from libuv may not have
any valid data in it, so don't copy it into the caller's FileInfo.

This was happening, expectedly, in functional/ex_cmds/write_spec.lua's
"write errors out correctly", which caused it to fail in certain
environments:

    test/functional/ex_cmds/write_spec.lua:130: Expected objects to be the same.
    Passed in:
    (string) 'Vim(write):E212: Can't open file for writing: not a directory'
    Expected:
    (string) 'Vim(write):E166: Can't open linked file for writing'
2020-07-31 17:59:33 -04:00
James McCoy
1153ac9036
Merge pull request #12699 from jamessan/getn 2020-07-31 10:27:57 -04:00
erw7
a4fe8bdc97
shada: fix failed assertion on exit (#12692)
If set the number of history saves is 0, assertions fail when inserting an entry on exit.
Dont insert an entry when the number of saves is 0 fixes the issue.

fixes #11497
2020-07-31 16:08:34 +02:00
James McCoy
55a885c179
lua: Use #var instead of deprecated table.getn(var) 2020-07-31 01:33:42 -04:00