Commit Graph

7977 Commits

Author SHA1 Message Date
ZyX
dc75766081 tests: Fix testlint errors 2017-04-03 03:07:01 +03:00
ZyX
9912043103 functests: Test some :write errors 2017-04-03 03:04:10 +03:00
ZyX
2dbd49f73c fileio: Save details about E212 error 2017-04-03 03:02:17 +03:00
ZyX
97a7f4745d eval: Add s flag, use p_fs by default, error out on unknown flag 2017-04-03 02:11:27 +03:00
ZyX
5dcf280445 fileio: Refactor msg_add_fname to something which needs no comments 2017-04-03 02:03:05 +03:00
ZyX
1c41b9c775 fileio: Clean up IObuff-manipulation mess 2017-04-03 01:39:09 +03:00
ZyX
8eb598c08e fixup! 2017-04-03 00:44:49 +03:00
ZyX
8dd9c6edd8 message: Do not use IObuff in emsgf 2017-04-03 00:40:48 +03:00
ZyX
364709bedb fileio: Refactor errmsg handling
Adds os_strerror() result to a number of places. Also since I could not track 
where err\* variables are NULL and where they are not, using macros to make sure 
that all three variables are set at once.

Removes #ifdef UNIX around the use of os_fsync, makes it use os_close in place 
of close in some places.
2017-04-03 00:35:29 +03:00
ZyX
b10880dadc eval: Make writefile() able to disable fsync() 2017-04-02 22:11:35 +03:00
Nikolai Aleksandrovich Pavlov
ddfa0359c6 unittests: Make it easier to determine on which _spec line it crashed (#6424)
Benchmarks:

Before change: 17.78s user 3.48s system  94% cpu 22.525 total
After change:  25.38s user 4.46s system 101% cpu 29.317 total
2017-04-02 13:25:47 +02:00
Justin M. Keyes
58422f17d8 Merge #6423 from justinmk/guicursor 2017-04-02 02:32:36 +02:00
James McCoy
a7569b50b7 Merge pull request #6338 from jamessan/llvm-update
Bump LLVM to 3.9
2017-04-01 20:09:26 -04:00
Justin M. Keyes
1ad5644006 Merge #6409 from ZyX-I/separate-clint
cmake: Add `clint` target to build Makefile
2017-04-02 01:20:16 +02:00
James McCoy
16babc6687 tui: Only enable/disable mouse when there's something to do (#6411)
If we get a mouse_on/mouse_off event, but the mouse is already in the
corresponding state, there's no need to send the event up to the
terminal.

Closes #4394
2017-04-02 00:00:42 +02:00
Justin M. Keyes
3a69dbfca6 api/cursor_style_set: mode descriptions 2017-04-01 23:29:10 +02:00
Justin M. Keyes
c2826a7830 'guicursor': Empty means "block cursor in all modes".
Also: update default 'guicursor' to match the documentation.
2017-04-01 23:14:05 +02:00
Matthieu Coudron
54bab0019b tui: 'guicursor' color
For now only supports valid hex colors (does not check for the validity
the hex color) when termguicolors is set, otherwise it won't attempt to
change the cursor color.
2017-04-01 23:14:05 +02:00
Matthieu Coudron
dd4a5fcbb6 tui: 'guicursor' shape #6044
Closes #2583
2017-04-01 23:14:05 +02:00
Justin M. Keyes
518f28f537 Merge #6422 from ZyX-I/fix-6420
eval,fileio: Omit additional fsync() call
2017-04-01 22:38:20 +02:00
Matthew Malcomson
337b6179df 'pastetoggle': support value >1 char (#6421)
If we `set pastetoggle=abcde`, and manually type it, then `vgetorpeek()`
sees part of the option before it has all been inserted into the
typebuffer.
To signify this it sets `keylen = KEYLEN_PART_KEY`, but the condition
about whether to return the current key from `vgetorpeek()` only checks
for `keylen = KEYLEN_PART_MAP`.
Add a check for `KEYLEN_PART_KEY` to account for the `'pastetoggle'`
option.
2017-04-01 21:50:29 +02:00
ZyX
19690d4a25 eval: Do not allocate FileDescriptor 2017-04-01 22:26:50 +03:00
Justin M. Keyes
0f6608d039 Merge #6418 from ZyX-I/better-unittests 2017-04-01 20:48:03 +02:00
ZyX
cc4523013f eval,fileio: Omit additional fsync() call
Fixes #6420
2017-04-01 21:15:13 +03:00
ZyX
ac22238b6a unittests: Replace two environment variables with one TRACE_LEVEL 2017-04-01 20:57:23 +03:00
Justin M. Keyes
33ff29fc74 Merge #6344 'vim-patch:7.4.2236,7.4.2306' 2017-04-01 17:42:15 +02:00
lonerover
45a13c4bbc vim-patch:7.4.2306
Problem:    Default value for 'langremap' is wrong.
Solution:   Set the right value. (Jürgen Krämer)  Add a test.

da9ce2cde1
2017-04-01 22:46:27 +08:00
lonerover
53da57d27a vim-patch:7.4.2236
Problem:    The 'langnoremap' option leads to double negatives.  And it does
            not work for the last character of a mapping.
Solution:   Add 'langremap' with the opposite value.  Keep 'langnoremap' for
            backwards compatibility.  Make it work for the last character of a
            mapping.  Make the test work.

920694c1b6
2017-04-01 22:45:36 +08:00
ZyX
2d158dde02 unittests: Fix linter error 2017-04-01 13:17:25 +03:00
ZyX
708a55ee15 unittests: Disable non-C-calls
Some benchmarks:

TRACE_EVERYTHING: 79.45s user 12.68s system 124% cpu 1:13.94  total

(default):        30.26s user  5.30s system  89% cpu   39.663 total
2017-04-01 13:16:25 +03:00
ZyX
9dd0d4f8b9 unittests: Add trace description right to the error message 2017-04-01 12:52:28 +03:00
ZyX
046d6a8dfe unittests: Collect traces
Some benchmarks:

MAIN_CDEFS + NO_TRACE:  3.81s user  1.65s system  33% cpu   16.140 total

MAIN_CDEFS:            73.61s user 10.98s system 154% cpu   54.690 total

NO_TRACE:              18.49s user  4.30s system  73% cpu   30.804 total

(default):             77.11s user 14.74s system 126% cpu 1:12.79  total
2017-04-01 12:25:10 +03:00
ZyX
8f7a48f46a unittests: Split itp implementation into multiple functions 2017-04-01 11:19:41 +03:00
ZyX
933d60bc23 unittests: Do not hang when error message is too long 2017-04-01 11:07:08 +03:00
Justin M. Keyes
8de53157b6 build: avoid cmake warning (#6417) 2017-04-01 03:22:56 +02:00
ZyX
6ddaace7ac ci: Do not shift if there are not enough arguments 2017-03-31 20:52:05 +03:00
ZyX
86f5b1276b ci: Add test watchdog and tracing for lint tests 2017-03-31 19:42:18 +03:00
ZyX
929c398aab ci: Enable tracing 2017-03-31 19:09:18 +03:00
ZyX
d9069b9fe4 ci: Check for exact value of CI_TARGET, not its emptyness 2017-03-31 17:39:18 +03:00
James McCoy
4bae3f48fe ci: Bump clang version to 3.9 2017-03-31 10:03:43 -04:00
James McCoy
1b276be6e5 ci: Use LLVM's trusty repo to match Travis' Ubuntu version 2017-03-31 10:03:43 -04:00
ZyX
4c20733f6b ci: Add ${NL} variable 2017-03-31 16:19:47 +03:00
ZyX
2da3caef1b ci: Do not quote MAKE_CMD 2017-03-31 16:17:38 +03:00
ZyX
1e87061294 makefile: Make lint target depend on clint 2017-03-31 16:08:02 +03:00
ZyX
2bf9d36ccd ci: Refactor CI scripts
1. CI_TARGET now determines which run_${CI_TARGET}.sh script to use. Defaults to
   `tests`.
2. Build no longer halts on the first failing suit: e.g. if functional tests
   failed it will continue with unit tests, etc.
3. All ${MAKE_CMD} occurrences moved to `top_make` function, added `build_make`
   as an alias to `make -C build` (`"${MAKE_CMD}" -C "${BUILD_DIR}"`) which is
   too verbose.

`suite.sh` was copied from powerline (tests/common.sh file), assumes running
with POSIX shells (and actually uses dash in powerline). Then some convenience
functions were added (run_test and below).
2017-03-31 16:06:17 +03:00
ZyX
4d0f90f94d cmake: Also depend on LINT_PRG 2017-03-31 16:04:18 +03:00
ZyX
4fc2be490c clint: Do not report zero errors 2017-03-31 16:04:18 +03:00
ZyX
c61858a997 cmake: Replace RunLint.cmake with code in src/nvim/CMakeLists.txt
This also removes LINT_FILE environment variable, other then that functionality 
is kept. It is expected that developers needing partial linting will use `make 
lint`, touching interesting file before (if not done already by writing to 
them).
2017-03-31 16:04:18 +03:00
ZyX
24fd125893 cmake: Allow failing to download small suppress files 2017-03-31 16:04:18 +03:00
ZyX
8204eaea7f cmake: Make Download.cmake check for errors
Copying from third-party/cmake/DownloadAndExtractFile.cmake.
2017-03-31 16:04:17 +03:00