Commit Graph

8959 Commits

Author SHA1 Message Date
Jonathan de Boyne Pollard
2c236fc67b tui: Track cursor visibility.
This fixes a test failure caused by dfaecb25f6a9a94f29a38d9f2d24a579b3dff5f
not tracking what the current visibility is and whether it matches the
current business state.
2017-06-10 09:00:15 +01:00
James McCoy
90f20bd7b1 pvscheck: Fix argument handling in do_recheck
[ci skip]
2017-06-09 16:42:43 -04:00
Jonathan de Boyne Pollard
cdfaecb25f tui: Eliminate more extraneous control sequences.
When higher layers flush the TUI layer output buffer, but there is
nothing in the buffer to flush, no longer does the TUI layer write out
unnecessary cnorm/civis sequences surrounding that nothing.
2017-06-09 19:50:13 +01:00
Jonathan de Boyne Pollard
6d35c5c7ec tui: Another linux terminfo capability fix
For the linux terminal type apply the same fixup to the terminfo civis
string that is applied to the cnorm string.
2017-06-09 19:33:17 +01:00
James McCoy
1a093c08d0 Merge pull request #6345 from brcolow/vim-7.4.2360
vim-patch:7.4.2360
2017-06-08 16:38:21 +00:00
Michael Ennen
edced212db vim-patch:7.4.2360
Problem:    Invalid memory access when formatting. (Dominique Pelle)
Solution:   Make sure cursor line and column are associated.

80c3fd7c55
2017-06-08 10:27:39 -04:00
Justin M. Keyes
16cce1ac17 Merge #6827 'Always enable logging' 2017-06-07 23:19:02 +02:00
James McCoy
d3d0c9a7b1 Merge pull request #5621 from jamessan/vim-7.4.1975
vim-patch:7.4.1975,7.4.1976,7.4.1977,7.4.1978,7.4.1979,7.4.1986,7.4.2029,7.4.2224,8.0.0219,8.0.0614
2017-06-07 14:05:46 +00:00
Jonathan de Boyne Pollard
2b35f40fc1 doco: Adjust TERM and terminfo doco.
Use a table and adjust cursor-shape a bit.
2017-06-07 14:21:53 +01:00
James McCoy
ca1ba1085a
lint 2017-06-06 21:38:31 -04:00
James McCoy
af59a290d8
*: Fix conversion warnings for tv_get_number*() 2017-06-06 21:38:31 -04:00
James McCoy
bf4de3f6f7
functests/msgpack: Correct representation of literal INT64_MIN
In order to generate INT64_MIN from literal values, it's necessary to
use "-0x7fffffffffffffff - 1".  Using "-0x8000000000000000" causes the
value to get clamped to INT64_MAX and then negated.
2017-06-06 21:38:31 -04:00
James McCoy
d69286c065
functests/msgpack: Use assert_equal() for more informative errors 2017-06-06 21:38:30 -04:00
James McCoy
601bf9642f
strings/tv_float: Explicitly cast v_number to float_T for -Wconversion 2017-06-06 21:38:27 -04:00
Justin M. Keyes
bc025ab117 doc: *standard-path*, *$NVIM_LOG_FILE* 2017-06-07 00:40:13 +02:00
Justin M. Keyes
b4b09afabd test: iswin(): detect without nvim session 2017-06-07 00:27:26 +02:00
Justin M. Keyes
d07661b9a3 log: Fall back to CWD-relative .nvimlog
If if the resolved $NVIM_LOG_FILE *and* stdpath("data")/log cannot be
created (e.g. because the XDG data directory does not exist), fall back
to .nvimlog in the current direcrtory.
2017-06-07 00:27:26 +02:00
Justin M. Keyes
a49c92fc5b test: Set $NVIM_LOG_FILE to test-local path
- Do not delete it: may need to inspect it after tests finished.
- Avoids writing to stderr in cases where the test-local $XDG_DATA_HOME
  was not created yet.
2017-06-07 00:27:26 +02:00
Justin M. Keyes
bb96b8219d log: set $NVIM_LOG_FILE; fallback to $XDG_DATA_HOME/nvim/log 2017-06-07 00:26:56 +02:00
Justin M. Keyes
05cdbbc18b ga_append_via_ptr: fix log arguments 2017-06-07 00:26:22 +02:00
Justin M. Keyes
eb6dd3e42d ci: Dump $NVIM_LOG_FILE contents 2017-06-07 00:26:21 +02:00
Justin M. Keyes
fe1af9c2bc log: Always enable; remove DISABLE_LOG
- Establish ERROR log level as "critical". Such errors are rare and will
  be valuable when users encounter unusual circumstances.
- Set -DMIN_LOG_LEVEL=3 for release-type builds
2017-06-07 00:26:21 +02:00
Justin M. Keyes
698ec9eb6e loop_close: Avoid infinite loop, and log it.
Avoids a hang, and also helps diagnose issues like:

https://github.com/neovim/neovim/pull/6594#issuecomment-298321826
2017-06-07 00:26:21 +02:00
Justin M. Keyes
f83d733318 log: log_uv_handles 2017-06-07 00:26:19 +02:00
James McCoy
2109fb18e6
eval/typval: Convert string to varnumber_T instead of intermediate long 2017-06-06 07:56:03 -04:00
James McCoy
6757c503bd
vim-patch:8.0.0614
Problem:    float2nr() is not exactly right.
Solution:   Make float2nr() more accurate.  Turn test64 into a new style test.
            (Hirohito Higashi, closes vim/vim#1688)

863e80b445
2017-06-06 07:39:33 -04:00
James McCoy
9281653233
Merge remote-tracking branch 'origin/master' into vim-7.4.1975 2017-06-06 07:33:50 -04:00
James McCoy
cb0abce5be Merge pull request #6854 from jamessan/vim-8.0.0156
vim-patch:8.0.0156,8.0.0158,8.0.0167,8.0.0168,8.0.0360,8.0.0477,8.0.0478,8.0.0176,8.0.0561
2017-06-06 11:26:07 +00:00
James McCoy
75c32b549b
lint 2017-06-06 06:15:16 -04:00
James McCoy
9a21d89b17
vim-patch:8.0.0561
Problem:    Undefined behavior when using backslash after empty line.
Solution:   Check for an empty line. (Dominique Pelle, closes vim/vim#1631)

478af67dd6
2017-06-06 06:15:16 -04:00
James McCoy
5f8411b7bf
vim-patch:8.0.0176
Problem:    Using :change in between :function and :endfunction fails.
Solution:   Recognize :change inside a function. (ichizok, closes vim/vim#1374)

70bcd7336f
2017-06-06 06:15:16 -04:00
James McCoy
d707b2a171
vim-patch:8.0.0478
Problem:    Tests use assert_true(0) and assert_false(1) to report errors.
Solution:   Use assert_report().

37175409d7
2017-06-06 06:15:16 -04:00
James McCoy
dafc14b969
vim-patch:8.0.0477
Problem:    The client-server test may hang when failing.
Solution:   Set a timer.  Add assert_report()

42205551b1
2017-06-06 06:15:16 -04:00
James McCoy
cb8efa4fef
vim-patch:8.0.0360
Problem:    Sometimes VimL is used, which is confusing.
Solution:   Consistently use "Vim script". (Hirohito Higashi)

b544f3c81f
2017-06-06 06:15:16 -04:00
James McCoy
0088ed0f1a
vim-patch:8.0.0168
Problem:    Still some float functionality is not covered by tests.
Solution:   Add more tests. (Dominique Pelle, closes vim/vim#1364)

872004132f
2017-06-06 05:07:14 -04:00
James McCoy
17d616037d
vim-patch:8.0.0167
Problem:    str2nr() and str2float() do not always work with negative values.
Solution:   Be more flexible about handling signs. (LemonBoy, closes vim/vim#1332)
            Add more tests.

08243d26d2
2017-06-06 05:07:14 -04:00
James McCoy
b1d4ef2b42
vim-patch:8.0.0158
Problem:    On MS-Windows some float functions return a different value when
            passed unusual values.  strtod() doesn't work for "inf" and "nan".
Solution:   Accept both results.  Fix str2float() for MS-Windows.  Also
            reorder assert function arguments.

6247361101
2017-06-06 05:07:14 -04:00
James McCoy
09eefbe92c
vim-patch:8.0.0156
Problem:    Several float functions are not covered by tests.
Solution:   Add float tests. (Dominique Pelle)

453b576ee5
2017-06-06 05:07:06 -04:00
Justin M. Keyes
45d92e2563 doc: clang scan-build 2017-06-06 04:03:24 +02:00
Jonathan de Boyne Pollard
b22a61cdbb tui: Recognize "Tc" terminfo capability.
This is a new convention pioneered by tmux.  It does not do much for
nvim; since nvim always looks to see whether it should be making up
"setrgbf" and "setrgbb" capabilities.  But it is a way for terminfo to
force this, irrespective of the hardwired list in the code, for more
terminal types.  On the gripping hand, updating terminfo descriptions to
actually have "setrgbf" and "setrgbb" capabilities so that nvim never
has to try to invent them in the first place, is as good if not better
an approach for overriding what is baked into the code.
2017-06-05 22:47:44 +01:00
Jonathan de Boyne Pollard
054b03e07a tui: Combine multiple attribute changes.
Use the terminfo set_attribute capability to set multiple attributes in one
control sequence, if it is available.
2017-06-05 22:12:53 +01:00
James McCoy
b3129b3791
eexe_mod_op: Explicitly cast varnumber_T to float_T for -Wconversion 2017-06-04 22:12:15 -04:00
James McCoy
eb5e4a2476
*: Disable UBSAN for VimL arithmetic implementation
After merging +num64, the 64-bit sanitizer builds show that Vim doesn't
buffer the user from C's UB in signed arithmetic.  Upstream doesn't
appear to be [interested] in fixing the issue, so suppress UBSAN until
someone decides to fix the problem.

N.B., the problem existed before but went unnoticed since the sanitizer
builds weren't being run in 32-bit mode.

[interested]: https://groups.google.com/d/topic/vim_dev/_tqf8eQy5eA/discussion
2017-06-04 22:12:15 -04:00
James McCoy
fb2b3f98bb
func_attr: Allow disabling UBSAN for a function 2017-06-04 22:12:15 -04:00
James McCoy
43534cab02
lint 2017-06-04 22:12:14 -04:00
James McCoy
2fb0a62553
vim-patch:8.0.0219
Problem:    Ubsan reports errors for integer overflow.
Solution:   Define macros for minimum and maximum values.  Select an
            expression based on the value. (Mike Williams)

7a40ea2138
2017-06-04 22:12:14 -04:00
James McCoy
55c93ea164
vim-patch:7.4.2224
Problem:    Compiler warnings with older compiler and 64 bit numbers.
Solution:   Add "LL" to large values. (Mike Williams)

af9c4c9b57

Equivalent change was made in ZyX's typval refactoring.
2017-06-04 22:12:14 -04:00
James McCoy
c3efb2804a
vim-patch:7.4.2029
Problem:    printf() does not work with 64 bit numbers.
Solution:   use the "L" length modifier. (Ken Takata)

38ee6b041e
2017-06-04 22:12:14 -04:00
James McCoy
9c01efd6fb
vim-patch:7.4.1986
Problem:    Compiler warns for loss of data.
Solution:   Use size_t instead of int. (Christian Brabandt)

fef524bbff

Equivalent change had already been made when merging earlier pack
patches.
2017-06-04 22:12:14 -04:00
James McCoy
03f5f78792
vim-patch:7.4.1979
Problem:    Getting value of binary option is wrong. (Kent Sibilev)
Solution:   Fix type cast.  Add a test.

2acfbed9db
2017-06-04 22:12:14 -04:00