Commit Graph

12042 Commits

Author SHA1 Message Date
Jan Edmund Lazo
57ff96be8e CI/AppVeyor: fix MSBuild hack for functional tests
PR #9087 changed the error string by removing 'Running', breaking the
MSBuild hack detecting failure for functional tests. If stdout or stderr
has a line with 'functional tests failed with error', fail the build.
2018-10-22 01:28:02 +02:00
Justin M. Keyes
565bbd1485
Merge #9146 from justinmk/fix-warnings 2018-10-21 23:48:43 +02:00
Justin M. Keyes
11ae6f418d fix warning: null arg passed to 'nonnull' param
Found by clang scan-build 5.0
2018-10-21 23:25:02 +02:00
Justin M. Keyes
902ca26856 fix warning: null arg passed to 'nonnull' param
Found by clang scan-build 5.0
2018-10-21 23:24:59 +02:00
Justin M. Keyes
f97496a21c fix warning: "Assigned value is garbage"
clang scan-build noticed that find_command() may bitmask `eap->flags`.
cmd_can_preview() only uses `ea.cmdidx`, but let's fix the warning...

Found by clang scan-build 5.0
2018-10-21 23:24:54 +02:00
Justin M. Keyes
2afebc4e5f fix warning: "Dead assignment"
`tv` is passed to the TYPVAL_ENCODE_CONV_FUNC_BEFORE_* macros, which
don't appear to actually use that parameter.

Found by clang scan-build 5.0
2018-10-21 23:24:50 +02:00
Justin M. Keyes
a8422818a7 fix warning: null pointer dereference
Found by clang scan-build 5.0
2018-10-21 23:24:46 +02:00
Justin M. Keyes
e0f6f46c1b fix warning: garbage/uninitialized value
According to clang scan-build, `fromcol` could be uninitialized at line
2645.

Found by clang scan-build 5.0
2018-10-21 23:24:40 +02:00
Justin M. Keyes
863dbbb3d4 fix warning: "Uninitialized argument"
clang scan-build thinks os_system() could set `do_profiling` flag.

Found by clang scan-build 5.0
2018-10-21 23:24:21 +02:00
Björn Linse
25bc656988
Merge pull request #9144 from bfredl/ui_event_compat
api/ui: verify compatibility of UI events
2018-10-21 22:01:50 +02:00
Björn Linse
bcab880bb6 api/ui: verify compatibility of UI events 2018-10-21 20:36:52 +02:00
Justin M. Keyes
f895b47d3f
man.vim: :Man! operates on buffer contents (#9139)
mandoc may not handle quoted MANPAGER arguments correctly. E.g. with
    export MANPAGER='nvim -u NORC -c "set ft=man"'
mandoc treats `"set` and `ft=man"'` as separate tokens.

To workaround that, provide :Man! so that MANPAGER can avoid quoting.

closes #9120
2018-10-21 17:38:25 +02:00
Justin M. Keyes
b227a3c8d3
Merge #9141 from justinmk/pvs 2018-10-21 17:01:14 +02:00
Justin M. Keyes
bbd8f4e9a4 tui.c: Fix ext.set_underline_color for !has_colon_rgb
PVS/V523: The 'then' statement is equivalent to the 'else' statement.
2018-10-20 23:09:49 +02:00
Justin M. Keyes
92f98b5bdf screen.c: Fix PVS/V560: condition is always false 2018-10-20 23:09:49 +02:00
Mahmoud Al-Qudsi
1cf50cbfd9 provider/nodejs: Simultaneously query npm and yarn #9054
ref #9001

Instead of serially querying npm and yarn for neovim, start both as a
job and then wait for a successful result from either.
2018-10-18 20:32:44 +02:00
Justin M. Keyes
edcf640f59
Merge #9130 'build: Fix for macOS 10.14/mojave'
fix #9050

Q: (from From #7891)
  > It turns out there's a difference between executing
  > /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
  > and /usr/bin/clang. CMake was picking up the former and with that it left off
  > a key include path. Why?

A: /usr/bin/clang is a shim that uses libxcselect/libxcrun under the hood.
   $ otool -L /usr/bin/clang
   /usr/bin/clang:
    /usr/lib/libxcselect.dylib (compatibility version 1.0.0, current version 1.0.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1252.200.5)

From https://macops.ca/developer-binaries-on-os-x-xcode-select-and-xcrun/ :
  > this shim binary loads functions in libxcselect.dylib that can locate the
  > path to the real binary, depending on how the system has been configured. One
  > part of this process is to check whether this path contains
  > usr/lib/libxcrun.dylib, and the xcrun tool, in which case it will invoke
  > xcrun to run the binary.
  > ...
  > (If all of this isn’t yet enough indirection for you, /usr/bin/xcrun itself
  > is a shim, and so libxcselect.dylib contains code to detect whether the
  > executed xcrun is a shim. Look for the __xcrun_shim segment in the __DATA
  > section output by the command: pagestuff /usr/bin/xcrun -a.)
2018-10-18 01:28:17 +02:00
Justin M. Keyes
3059516e8a
Merge #9086 'vim-patch:8.1.0448' 2018-10-18 00:47:30 +02:00
dm1try
31f63c8d55 build/macOS: provide SDK path to deps compiler
otherwise, system headers cannot be found on Mojave
they were moved from /usr/include to SDK path
2018-10-17 16:26:28 +03:00
dm1try
913588466d build/macOS: fix luajit install step
prevent luajit to assigning default value to MACOSX_DEPLOYMENT_TARGET
ref #9050
2018-10-17 16:26:19 +03:00
Justin M. Keyes
aff64b3a52 Merge #9124 'vim-patch:8.0.1672' 2018-10-17 09:51:09 +02:00
Justin M. Keyes
9642903dea
test: Improve 008_autocommands_spec reliability (#9129)
Sometimes 008_autocommands_spec fails like this:

    [ RUN      ] autocommands that delete and unload buffers: BufUnload, VimLeave: -- Output to stderr:
    CMake Error at /home/travis/build/neovim/neovim/cmake/RunTests.cmake:53 (message):
      functional tests failed with error: 1

The final :quit + wait() is a race. Use command() instead, which is
synchronous.  Use command('silent! ...') everywhere else too, because
it's clearer instead of feeding input and clearing the expected errors
with CTRL-L.
2018-10-17 09:24:45 +02:00
Justin M. Keyes
2d531d296f
Merge #9131 from janlazo/vim-8.0.0670 2018-10-17 08:13:09 +02:00
Björn Linse
e311b019a1
Merge pull request #6930 from bfredl/expectfix
tests: detect and fix fragile sceen tests, and mark intentional unchanged expect():s
2018-10-16 23:34:11 +02:00
Jan Edmund Lazo
090008f311 vim-patch:8.0.1067: try/catch in timer does not prevent it from being stopped
Problem:    Using try/catch in timer does not prevent it from being stopped.
Solution:   Reset the exception context and use did_emsg instead of
            called_emsg.
e723c42836
2018-10-16 00:03:13 -04:00
Jan Edmund Lazo
7d7691e85f vim-patch:8.0.0670: can't use input() in a timer callback
Problem:    Can't use input() in a timer callback. (Cosmin Popescu)
Solution:   Reset vgetc_busy and set timer_busy. (Ozaki Kiichi, closes vim/vim#1790,
            closes vim/vim#1129)
1e8e14552e
2018-10-15 21:22:43 -04:00
Justin M. Keyes
6476d081be test/old: stub CanRunVimInTerminal() 2018-10-16 00:26:01 +02:00
Justin M. Keyes
ee94eecbd4 vim-patch:8.1.0448: cursorline not removed when using 'cursorbind'
Problem:    Cursorline not removed when using 'cursorbind'. (Justin Keyes)
Solution:   Store the last cursor line per window. (closes vim/vim#3488)
4a5abbd613
2018-10-16 00:15:09 +02:00
Björn Linse
c8810a51a3 tests: improve robustness of immediate successes in screen tests 2018-10-15 20:13:11 +02:00
Jan Edmund Lazo
8fd092f3ff vim-patch:8.1.0476: memory leaks in test_escaped_glob (#9127)
Problem:    Memory leaks in test_escaped_glob.
Solution:   Avoid failure when running the shell, use the sandbox.
a2aad02830
2018-10-14 16:23:46 -07:00
Jan Edmund Lazo
9c2d5f1a33 functionaltest: map error does not cancel prompt 2018-10-14 09:08:56 -04:00
James McCoy
e568ac7a68
Merge pull request #9123 from jamessan/unibilium-parsing-fix
third-party/unibilium: Fix parsing of extended capability entries
2018-10-13 22:11:58 -04:00
Jan Edmund Lazo
e7ba325298 vim-patch:8.0.1672: error during completion causes command to be cancelled
Problem:    Error during completion causes command to be cancelled.
Solution:   Reset did_emsg before waiting for another character. (Tom M.)
72532d354e
2018-10-13 21:47:41 -04:00
James McCoy
399864157b
third-party/unibilium: Fix parsing of extended capability entries
In the 20180331 release, the format was slightly changed:

> 20180331
>         + improve terminfo write/read by modifying the fourth item of the
>           extended header to denote the number of valid strings in the extended
>           string table (prompted by a comment in unibilium's sources).

Since the number of valid string capabilities is not necessarily the
same as extstrslen, it's not possible to sanity check the total number
of items up front anymore.
2018-10-13 20:24:02 -04:00
Justin M. Keyes
c9baaa9200
Merge #9095 'CI/travis/macOS: fix missing pip3' 2018-10-13 15:59:49 -07:00
Justin M. Keyes
aa87dd2b89
Merge #9122 from janlazo/vim-8.1.0473 2018-10-13 14:40:16 -07:00
Justin M. Keyes
78418e17e9 CI/travis/macOS: silence non-error messages from homebrew
Reduces the log size by 11% (1100/9670 lines).
2018-10-13 23:34:49 +02:00
Justin M. Keyes
3d2493a3fd CI/travis/macOS: use "sudo rm" to remove cores
After bumping Travis macOS to 10.13, it now hangs at:

    + check_core_dumps --delete quiet
    + local del=
    + test --delete = --delete
    + del=1
    + shift
    + local app=quiet
    + test osx = osx
    ++ find /cores/ -type f -print
    + local 'cores=/cores//core.554
    /cores//core.641
    /cores//core.801'
    + test -z '/cores//core.554
    /cores//core.641
    /cores//core.801'
    + local core
    + for core in '$cores'
    + test 1 = 1
    + print_core quiet /cores//core.554
    + local app=quiet
    + local core=/cores//core.554
    + test quiet = quiet
    + echo 'Found core /cores//core.554'
    Found core /cores//core.554
    + return 0
    + rm /cores//core.554
    override r--------  root/admin for /cores//core.554?

The cores are always present on the Travis macOS 10.13 image! Hilarious.
2018-10-13 23:34:49 +02:00
Justin M. Keyes
e39dade80b test: adjust timer tests
Timer tests are less reliable on Travis CI macOS 10.12 (most egregious).
Also somewhat on 10.13.
2018-10-13 23:34:49 +02:00
Jan Edmund Lazo
12376cc01c memline: process_still_running is bool 2018-10-13 17:16:42 -04:00
Jan Edmund Lazo
726baefdf7 vim-patch:8.1.0473: user doesn't notice file does not exist when swap file does
Problem:    User doesn't notice file does not exist when swap file does.
Solution:   Add a note that the file cannot be found.  Make the "still
            running" notice stand out.
d6105cb408
2018-10-13 17:13:47 -04:00
Justin M. Keyes
0995f460fb CI/travis/macOS: fix missing pip3
homebrew or Travis changed something, now `pip3` isn't in $PATH.
`ls /usr/local/opt/python/libexec/bin` confirmed this, no matter what
brew reinstall/relink/upgrade are used.

Bumping the macOS image to 10.12 or 10.13 makes the problem go away.

    ==> Processing gcc49 formula rename to gcc@4.9
    ==> Unlinking gcc49
    ==> Moving gcc49 versions to /usr/local/Cellar/gcc@4.9
    ==> Relinking gcc@4.9
    Warning: gcc@4.9 is outdated!
    To avoid broken installations, as soon as possible please run:
      brew upgrade
    Or, if you're OK with a less reliable fix:
      brew upgrade gcc@4.9
    python info:
      Python 2.7.12
      Python 2.7.12
      ci/before_install.sh: line 18: python3: command not found
      pip 8.1.2 from /usr/local/lib/python2.7/site-packages (python 2.7)
      pip 8.1.2 from /usr/local/lib/python2.7/site-packages (python 2.7)
      ci/before_install.sh: line 21: pip3: command not found
      pyenv versions:
      * system (set by /Users/travis/.pyenv/version)
    Upgrade Python 3.
    To restore the stashed changes to /usr/local/Homebrew run:
      'cd /usr/local/Homebrew && git stash pop'
    ==> Caveats
    Python has been installed as
      /usr/local/bin/python3
    Unversioned symlinks `python`, `python-config`, `pip` etc. pointing to
    `python3`, `python3-config`, `pip3` etc., respectively, have been installed into
      /usr/local/opt/python/libexec/bin
    If you need Homebrew's Python 2.7 run
      brew install python@2
    Pip, setuptools, and wheel have been installed. To update them run
      pip3 install --upgrade pip setuptools wheel
    You can install Python packages with
      pip3 install <package>
    They will install into the site-package directory
      /usr/local/lib/python3.7/site-packages
    See: https://docs.brew.sh/Homebrew-and-Python
    ==> Summary
    º  /usr/local/Cellar/python/3.7.0: 8,864 files, 153.8MB, built in 6 minutes 32 seconds
    ...
    Upgrade Python 3 pip.
    ci/before_install.sh: line 30: pip3: command not found
    travis_time🔚0d23f522:start=1538818824750644000,finish=1538819451424021000,duration=626673377000
    The command "ci/before_install.sh" failed and exited with 127 during .
    Your build has been stopped.
    /Users/travis/.travis/job_stages: line 373: shell_session_update: command not found

    ==> Processing gcc49 formula rename to gcc@4.9
    ==> Unlinking gcc49
    ==> Moving gcc49 versions to /usr/local/Cellar/gcc@4.9
    ==> Relinking gcc@4.9
    Warning: gcc@4.9 is outdated!
    To avoid broken installations, as soon as possible please run:
      brew upgrade
    Or, if you're OK with a less reliable fix:
      brew upgrade gcc@4.9
    python info:
      Python 2.7.12
      Python 2.7.12
      ci/before_install.sh: line 18: python3: command not found
      pip 8.1.2 from /usr/local/lib/python2.7/site-packages (python 2.7)
      pip 8.1.2 from /usr/local/lib/python2.7/site-packages (python 2.7)
      ci/before_install.sh: line 21: pip3: command not found
      pyenv versions:
      * system (set by /Users/travis/.pyenv/version)
    Upgrade Python 3.
    To restore the stashed changes to /usr/local/Homebrew run:
      'cd /usr/local/Homebrew && git stash pop'
    ==> Caveats
    Python has been installed as
      /usr/local/bin/python3
    Unversioned symlinks `python`, `python-config`, `pip` etc. pointing to
    `python3`, `python3-config`, `pip3` etc., respectively, have been installed into
      /usr/local/opt/python/libexec/bin
    If you need Homebrew's Python 2.7 run
      brew install python@2
    Pip, setuptools, and wheel have been installed. To update them run
      pip3 install --upgrade pip setuptools wheel
    You can install Python packages with
      pip3 install <package>
    They will install into the site-package directory
      /usr/local/lib/python3.7/site-packages
    See: https://docs.brew.sh/Homebrew-and-Python
    ==> Summary
    º  /usr/local/Cellar/python/3.7.0: 8,864 files, 153.8MB, built in 6 minutes 32 seconds
    ...
    Upgrade Python 3 pip.
    ci/before_install.sh: line 30: pip3: command not found
    travis_time🔚0d23f522:start=1538818824750644000,finish=1538819451424021000,duration=626673377000
    The command "ci/before_install.sh" failed and exited with 127 during .
    Your build has been stopped.
    /Users/travis/.travis/job_stages: line 373: shell_session_update: command not found
2018-10-13 22:33:01 +02:00
Justin M. Keyes
d14283c7a0 Merge #9118 2018-10-13 21:07:54 +02:00
Justin M. Keyes
717e2db274 Revert "vim-patch:8.0.0971: 'winptydll' missing from :options"
Revert f4e2df4527.
We don't support 'winptydll' and probably don't have any reason to.
2018-10-13 21:06:26 +02:00
Björn Linse
79a11ecfd3
Merge pull request #9121 from bfredl/virt_invalid
API: make nvim_buf_set_virtual_text handle invalid chars
2018-10-13 20:15:28 +02:00
Jan Edmund Lazo
824f36a980 vim-patch:8.0.1590: padding in list type wastes memory (#9119)
Problem:    Padding in list type wastes memory.
Solution:   Reorder struct members to optimize padding. (Dominique Pelle,
            closes vim/vim#2704)
1a84024037
2018-10-13 10:56:20 -07:00
Reto Schnyder
bddcbbb571 signs: Add "numhl" argument #9113
close #9113
ref #9040
2018-10-13 19:39:56 +02:00
Björn Linse
3d84cf6ff4 api: make nvim_buf_set_virtual_text handle invalid chars
Clients are supposed to supply only valid text, but if it is
invalid, translate it rather than messing up the screen
2018-10-13 16:37:17 +02:00
James McCoy
8bbb28b973
Merge pull request #8968 from ckelsel/vim-8.0.0685
[RFC] vim-patch:8.0.0685
2018-10-12 22:04:39 -04:00
Jan Edmund Lazo
64b44018fa vim-patch:8.0.1843: entry for 'wrap' in options window is wrong
Problem:    Entry for 'wrap' in options window is wrong. (John Little)
Solution:   Make the change apply locally.
8776889b5b
2018-10-12 21:55:53 -04:00