Commit Graph

11291 Commits

Author SHA1 Message Date
Justin M. Keyes
c500f22f3c
Merge #8498 from janlazo/vim-8.0.0523 2018-06-08 08:15:37 +02:00
Jan Edmund Lazo
be68f218ff vim-patch:8.0.0355: using uninitialized memory when 'isfname' is empty (#8493)
Problem:    Using uninitialized memory when 'isfname' is empty.
Solution:   Don't call getpwnam() without an argument. (Dominique Pelle,
            closes vim/vim#1464)
187a4f2814
2018-06-08 08:10:38 +02:00
Jan Edmund Lazo
4871f26c22 vim-patch:8.0.0586: no test for mapping timing out (#8501)
Problem:    No test for mapping timing out.
Solution:   Add a test.
b7637c44c2
2018-06-08 08:07:31 +02:00
Jan Edmund Lazo
bd736a98e3 vim-patch:8.0.0560: :windo allows for ! but it's not supported (#8500)
Problem:    :windo allows for ! but it's not supported.
Solution:   Disallow passing !. (Hirohito Higashi)
451a4a1cb7
2018-06-08 08:06:32 +02:00
Jan Edmund Lazo
231539cf3c lint 2018-06-07 21:44:27 -04:00
林千里
451c48a092 terminal: flush vterm output buffer on pty output #8486
Fixes #4151

libvterm uses an "output buffer" for terminal reporting
(e.g. \e[6n to report cursor position)
Flush it in on_channel_output() not just terminal_send_key()

See also this line from pangoterm:
https://bazaar.launchpad.net/~leonerd/pangoterm/trunk/view/607/pangoterm.c#L2159
2018-06-08 02:18:27 +02:00
Jan Edmund Lazo
34c0688790 vim-patch:8.0.0523: dv} deletes part of a multi-byte character.
Problem:    dv} deletes part of a multi-byte character. (Urtica Dioica)
Solution:   Include the whole character.
bf3d58073f
2018-06-07 19:41:30 -04:00
Justin M. Keyes
db68d1d638
Merge #8491 from janlazo/vim-8.0.0255 2018-06-07 18:31:50 +02:00
Jan Edmund Lazo
e0d39d8e53 vim-patch:8.0.0256: missing changes to one file breaks test
Problem:    Tests fail because some changes were not included.
Solution:   Add changes to evalfunc.c
3a29abcb61
2018-06-07 12:02:57 -04:00
Justin M. Keyes
3abf17ae88
API: validation: mention invalid method name (#8489) 2018-06-07 10:56:44 +02:00
Jan Edmund Lazo
5a82afa17a vim-patch:8.0.0265: ml_get error when :pydo deletes lines (#8492)
Problem:    May get ml_get error when :pydo deletes lines or switches to
            another buffer. (Nikolai Pavlov, issue vim/vim#1421)
Solution:   Check the buffer and line every time.
a58883b4ea

(We only include the tests, the Vim code changes are N/A for Nvim.)
2018-06-07 10:06:06 +02:00
Jan Edmund Lazo
7f6c1d256f vim-patch:8.0.0254: error message of assert functions (#8488)
Problem:    When using an assert function one can either specify a message or
            get a message about what failed, not both.
Solution:   Concatenate the error with the message.
c7b831ca15
2018-06-07 09:59:45 +02:00
Jan Edmund Lazo
2d456f84d1 vim-patch:8.0.0255: setpos() does not use the buffer argument for all marks
Problem:    When calling setpos() with a buffer argument it often is ignored.
            (Matthew Malcomson)
Solution:   Make the buffer argument work for all marks local to a buffer.
            (neovim vim/vim#5713)  Add more tests.
f13e00b2cf
2018-06-06 20:37:35 -04:00
Justin M. Keyes
36ac80d5dd
Merge #8464 from justinmk/cmake-findpkg-required 2018-06-06 01:52:29 +02:00
Justin M. Keyes
f795c3ce7c ex_getln.c: Fix PVS/V519: variable assigned twice 2018-06-06 01:15:37 +02:00
Justin M. Keyes
ec29eeef43 win/build: avoid "C4142: benign redefinition of type"
ssize_t is already typedef's by libuv:uv-win.h
2018-06-06 00:58:58 +02:00
Justin M. Keyes
b7032cf1e3 win: enable DYNAMIC_ICONV 2018-06-06 00:58:58 +02:00
Justin M. Keyes
90e3dd9220 makedeps.bat 2018-06-06 00:58:57 +02:00
Justin M. Keyes
7303dd3e54 win/build: download iconv, gettext tools
- We need the gettext tools (msgmerge.exe) because these aren't built
  when we build from source (not trivial).
- We can use the pre-built libiconv-2.dll for DYNAMIC_ICONV_DLL.
2018-06-06 00:58:57 +02:00
Justin M. Keyes
420379330e cmake/FindLibIntl.cmake: handle passive case explicitly
If check_c_source_compiles() succeeded (HAVE_WORKING_LIBINTL is set)
then the result of find_xxx() doesn't matter. This happens on systems
(linux+glibc) where libintl is available passively.

This allows `find_package(LibIntl REQUIRED)` to work and will still
correctly fail (REQUIRED) on systems lacking libintl.
2018-06-06 00:58:57 +02:00
Justin M. Keyes
21c9db1861 build/CMake: find_package(… REQUIRED)
"Always use `find_package` with `REQUIRED`."

- We make an exception for LuaJit (not REQUIRED): the `nvim-test` target
  is included only if we can find LuaJit.

This is partially a cargo-cult (reference below), but it uncovered at
least one problem: `find_package(LibIntl REQUIRED)` fails on my vanilla
ubuntu 16.04 system.

ref: https://schneide.blog/2017/11/06/4-tips-for-better-cmake/

> optional dependencies is nice, but skipping on REQUIRED is not the way
> you want to do it. In the worst case, some of your features will just
> not work if those packages are not found, with no explanation
> whatsoever. Instead, use explicit feature-toggles (e.g. using option())
> that either skip the find_package call or use it with REQUIRED, so the
> user will know that another lib is needed for this feature.
2018-06-06 00:58:57 +02:00
Justin M. Keyes
5861dc5966
Merge #8461 from bfredl/scrollstatus 2018-06-06 00:34:08 +02:00
Jan Edmund Lazo
078202d6f8 vim-patch:8.0.0675: 'colorcolumn' has a higher priority than 'hlsearch' (#8483)
Problem:    'colorcolumn' has a higher priority than 'hlsearch', it should be
            the other way around. (Nazri Ramliy)
Solution:   Change the priorities. (LemonBoy, closes vim/vim#1794)
774e5a9673
2018-06-05 17:10:07 +02:00
Justin M. Keyes
d9d91bbfef
Merge #8482 'test: give more time for nodejs' 2018-06-05 14:08:32 +02:00
Jan Edmund Lazo
6ffcc2b800 fixup: exclude node_modules/ for crash detection
node.js client uses lodash which has core.js.
2018-06-05 07:33:26 -04:00
Justin M. Keyes
ae927a49f7
Merge #8479 from janlazo/vim-8.0.0529 2018-06-05 08:43:01 +02:00
Jan Edmund Lazo
b2633bba73 vim-patch:8.0.0851: 'smartindent' is used even when 'indentexpr' is set (#8481)
Problem:    'smartindent' is used even when 'indentexpr' is set.
Solution:   Ignore 'smartindent' when 'indentexpr' is set. (Hirohito Higashi)
69a76feda9

---

This also fixes "delfunction!" which was not merged fully in  a185ab70fd (vim-patch:8.0.0655)
2018-06-05 08:20:38 +02:00
Jan Edmund Lazo
f274b84e1e test: give more time for nodejs
Link neovim package to project root directory.
Increase delay to 3 seconds.
Reduce the total lines in temporary node scripts.
2018-06-04 19:42:28 -04:00
Jan Edmund Lazo
2ab7165214 lint 2018-06-04 17:51:15 -04:00
Jan Edmund Lazo
21aa4bc428 vim-patch:8.0.0623: error for invalid regexp is not very informative
Problem:    The message "Invalid range" is used for multiple errors.
Solution:   Add two more specific error messages. (Itchyny, Ken Hamada)
966e58e413
2018-06-04 08:44:19 -04:00
Jan Edmund Lazo
fe5c891fe0 vim-patch:8.0.0529: line in test commented out
Problem:    Line in test commented out.
Solution:   Uncomment the lines for character classes that were failing before
            8.0.0519. (Dominique Pelle, closes vim/vim#1599)
13489b9c41
2018-06-04 08:38:27 -04:00
Justin M. Keyes
d8c7ff1335 cleanup, test interactive -E 2018-06-04 02:09:28 +02:00
Justin M. Keyes
1f300e08b8 win/startup: remove --literal
Fixes 2 failing tests in startup_spec.lua.

The Windows-only `--literal` option complicates support of "stdin-as-text
+ file-args" (#7679).  Could work around it, but it's not worth
the trouble:
- users have a reasonable (and englightening) alternative: nvim +"n *"
- "always literal" is more consistent/predictable
- avoids platform-specific special-case

Unrelated changes:
- Replace fileno(stdxx) with STDXX_FILENO for consistency (not motivated
  by any observed technical reason).
2018-06-04 02:09:27 +02:00
Justin M. Keyes
4211255c75 startup: allow explicit "-" file arg with --headless 2018-06-04 02:09:27 +02:00
Justin M. Keyes
63058fb5b0 startup: fix -es/-Es so they are actually silent
silent-mode (-es/-Es) has been broken for years.  The workaround up to
now was to include --headless.  But --headless is not equivalent because
it prints all messages, not the limited subset defined by silent-mode.
2018-06-04 02:09:27 +02:00
Justin M. Keyes
787ae1b38b startup: silent-mode is not full_screen
silent-mode (AKA batch-mode, -es/-Es) by definition should not behave
like a UI.

There are still some places that check `full_screen` to decide behavior,
e.g. msg_start().  Future: maybe eliminate `full_screen`, check
`ui_active()` instead?
2018-06-04 02:09:27 +02:00
Justin M. Keyes
d00ef758c3 lint 2018-06-04 02:09:24 +02:00
Justin M. Keyes
4b70ebe013 startup: stdin-text with -E, -Es (improved Ex-mode)
Special-case for -E/-Es (as opposed to -e/-es).

-es/-Es is the only mode that really allows N/Vim to work as a batch
script engine.  Adding a new flag (say `-x`) would involve a lot of
churn: -es/-Es is implemented by checking `exmode_active` in numerous
places.

This commit does not change -es because some scripts use it. But scripts
are unlikely to use -Es because it is not functionally different from
-es.

Also, both -es and -Es were broken in Nvim for years and no one
mentioned it...
2018-06-04 02:07:40 +02:00
Justin M. Keyes
905d4d78fc startup: stdin-text with file args 2018-06-04 02:07:40 +02:00
Justin M. Keyes
51e817dc1b startup: stdin as text instead of commands
Treat stdin as text by default (so the "-" file is not needed):
    echo foo | nvim

It works with file args (implemented in next commit), too:
    echo foo | nvim file1.txt file2.txt

Why? Because:
- Execution of input is (1) almost always unintentional/confusing,
  and (2) potentially destructive.
- Avoids the need for time-delayed warning.  #7659
- The _common_ case is to open text in a buffer, not send commands.

Note:
- Not for Ex-mode (-es) because it is used by scripts.  But maybe `-Es`?
- Not for --headless, because stdio may be a protocol stream and may be
  used for any purpose by stdioopen().

To treat stdin as Normal-mode commands, use `-s -` instead:
    echo ifoo | nvim -s -
Other alternatives:
  - Replay a register. E.g. the following mostly works, except @q aborts
    on any "beep" (e.g. if the cursor can't move).
    nvim -c '%d q|norm @q' -
  - Future: Let `:%source` work with unsaved buffer contents?

closes #2087
closes #7659
2018-06-04 02:07:39 +02:00
Justin M. Keyes
fad748dffa main.c: remove check_tty(), delayed warning
This code was essentially dead because this condition:
    (!parmp->err_isatty && (!parmp->output_isatty || !parmp->input_isatty))
is almost never true.

ref #7659
2018-06-04 02:07:39 +02:00
Justin M. Keyes
488f6ecdda lint 2018-06-04 02:07:39 +02:00
Justin M. Keyes
a1f562b044 doc/man: brevity, clarity 2018-06-04 02:07:39 +02:00
Justin M. Keyes
cf92a76285
vim-patches: 8.0.0399 8.0.0401 (#8475)
vim-patch:8.0.0399: crash when using balloon_show() when not supported
Problem:    Crash when using balloon_show() when not supported. (Hirohito
            Higashi)
Solution:   Check for balloonEval not to be NULL. (Ken Takata)
caf6434ac9

vim-patch:8.0.0401: test fails with missing balloon feature
Problem:    Test fails with missing balloon feature.
Solution:   Add check for balloon feature.
a0107bdf87

vim-patch:8.0.0414: balloon eval is not tested
2018-06-04 01:58:36 +02:00
Jan Edmund Lazo
7795829767 vim-patch:8.0.1237: ":set scroll&" often gives an error (#8473)
Problem:    ":set scroll&" often gives an error.
Solution:   Don't use a fixed default value, use half the window height. Add a
            test. (Ozaki Kiichi, closes vim/vim#2104)
af2d20c628
2018-06-04 01:31:37 +02:00
Marvim the Paranoid Android
807a16dbc1 version.c: update [ci skip] (#8413)
vim-patch:8.0.0349: redrawing errors with GTK 3
vim-patch:8.0.0363: Travis is too slow to keep up with patches
vim-patch:8.0.0366: build fails with tiny features
vim-patch:8.0.0373: build fails without +folding
vim-patch:8.0.0397: can't build with +viminfo but without +eval
vim-patch:8.0.0410: newer gettext/iconv library has extra dll file-
vim-patch:8.0.0418: ASAN logs are disabled
vim-patch:8.0.0445: getpgid is not supported on all systems-
vim-patch:8.0.0449
vim-patch:8.0.0462: failure of an MS-Windows test may go unnoticed
vim-patch:8.0.0494: build failure with older compiler on MS-Windows
vim-patch:8.0.0501: on MS-Windows ":!start" does not work as expected
vim-patch:8.0.0508: Coveralls no longer shows per-file coverage
vim-patch:8.0.0509: no link to codecov.io results
vim-patch:8.0.0510: typo in link to codecov.io results
vim-patch:8.0.0512: check for available characters takes too long
vim-patch:8.0.0521: GtkForm handling is outdated
vim-patch:8.0.0527: leftover file from RISC OS
vim-patch:8.0.0534: defaults.vim does not work well with tiny features
vim-patch:8.0.0557: GTK: using static gravities is not useful
vim-patch:8.0.0566: setting nocompatible for the tiny version moves the cursor
vim-patch:8.0.0570: can't run make with several jobs
vim-patch:8.0.0573: running parallel make after distclean fails
vim-patch:8.0.0576: can't build when configure choses "install-sh"
vim-patch:8.0.0578: :simalt on MS-Windows does not work properly
vim-patch:8.0.0589: :simalt still does not work
vim-patch:8.0.0594: build failure when windows feature is missing
vim-patch:8.0.0619: GUI gets stuck if timer uses feedkeys()
vim-patch:8.0.0624: warning for unused variable in tiny build
vim-patch:8.0.0638: cannot build with new MSVC version 
vim-patch:8.0.0651: build failure without the auto command feature
vim-patch:8.0.0695: missing dependencies breaks parallel make
vim-patch:8.0.0711: cannot build without the wildmenu feature
vim-patch:8.0.0756: cannot build libvterm with MSVC 
vim-patch:8.0.0757: libvterm MSVC Makefile not included in the distribution
vim-patch:8.0.0765: build fails with tiny features
vim-patch:8.0.0767: build failure with Athena and Motif
vim-patch:8.0.0780: build failure on Travis
vim-patch:8.0.0786: build failures on Travis 
vim-patch:8.0.0796: no coverage on Travis with clang 
vim-patch:8.0.0814: file in Filelist does not exist
vim-patch:8.0.0961: the script to build the installer does not include winpty
vim-patch:8.0.0989: ActiveTcl dll name has changed in 8.6.6
vim-patch:8.0.1032: "make tags" doesn't work well on MS-Windows-
vim-patch:8.0.1050: terminal window feature not included by default
vim-patch:8.0.1056: cannot build with +diff but without +multi_byte-
vim-patch:8.0.1084: GTK build has compiler warnings 
vim-patch:8.0.1086: can't build with GTK 3
vim-patch:8.0.1098: build failure if libvterm installed
vim-patch:8.0.1099: warnings for GDK calls
vim-patch:8.0.1122: vimtutor.bat doesn't work well with vim.bat
vim-patch:8.0.1124: use of MZSCHEME_VER is unclear
vim-patch:8.0.1147: fail to build with tiny features
vim-patch:8.0.1156: trouble from removing one -W argument from Perl CFLAGS
vim-patch:8.0.1178: using old compiler on MS-Windows
vim-patch:8.0.1183: MS-Windows build instructions are outdated
vim-patch:8.0.1185: Ruby library includes minor version number
vim-patch:8.0.1187: building with lua fails for OSX on Travis
vim-patch:8.0.1196: crash when t_RF is not set
vim-patch:8.0.1212: MS-Windows: tear-off menu does not work on 64 bit
vim-patch:8.0.1233: typo in dos installer
vim-patch:8.0.1235: cannot disable the terminal feature in a huge build
vim-patch:8.0.1252: incomplete translations makefile for MinGW/Cygwin
vim-patch:8.0.1268: PC install instructions are incomplete
vim-patch:8.0.1288: GUI: cannot drag the statusline of a terminal window
vim-patch:8.0.1294: GUI: get stuck when splitting a terminal window
vim-patch:8.0.1301: generated license file for NSIS has a modeline
vim-patch:8.0.1313: missing dependencies cause parallel make to fail
vim-patch:8.0.1314: build fails on Mac
vim-patch:8.0.1351: warning for unused variables building with MinGW
vim-patch:8.0.1373: no error when settting 'renderoptions' before starting GUI
vim-patch:8.0.1379: configure check for selinux does not check for header file
vim-patch:8.0.1385: Python 3.5 is getting old
vim-patch:8.0.1390: DirectX scrolling can be slow, vertical positioning is off
vim-patch:8.0.1392: build fails with --with-features=huge --disable-channel
vim-patch:8.0.1399: warnings and errors when building tiny version
vim-patch:8.0.1401: cannot build with GTK but without XIM
vim-patch:8.0.1407: GUI: CursorHold may trigger before 'updatetime'
vim-patch:8.0.1431: MS-Windows: vimtutor fails if %TMP% has special chars
vim-patch:8.0.1444: missing -D_FILE_OFFSET_BITS=64 may cause problems
vim-patch:8.0.1450: GUI: endless loop when stopping cursor blinking
vim-patch:8.0.1466: older GTK versions don't have gtk_entry_get_text_length()
vim-patch:8.0.1471: on MS-Windows CursorIM highlighting no longer works
vim-patch:8.0.1473: MS-Windows: D&D fails between 32 and 64 bit apps
vim-patch:8.0.1474: Visual C 2017 has multiple MSVCVER numbers
vim-patch:8.0.1530: dump test fails when using a shadow directory-
vim-patch:8.0.1548: screen dump test script not included in distribution-
vim-patch:8.0.1555: build error for some combination of features
vim-patch:8.0.1559: build failure without GUI
vim-patch:8.0.1560: build failure without GUI on MS-Windows 
vim-patch:8.0.1800: X11: getting color is slow-
vim-patch:8.0.1808: can't build without TGETENT-
vim-patch:8.0.1822: make uninstall does not remove colors/tools-
vim-patch:8.0.1826: configure uses old compiler flag-
vim-patch:8.0.1828: get no clue why :gui does not fork-
vim-patch:8.0.1833: X11: ":echo 3.14" gives E806- 
vim-patch:8.0.1834: GUI: find/replace dialog does not handle some chars-
vim-patch:8.0.1847: some build options don't have an example-
2018-06-04 01:13:00 +02:00
Justin M. Keyes
32935c8612
Merge #8414 'Windows fixes' 2018-06-03 23:44:06 +02:00
b-r-o-c-k
a80f73f043 deps: Fix libvterm and libtermkey escape sequences for MSVC
The escape sequence `\e` is non-standard and not supported by MSVC.
It caused the terminal emulator to incorrectly interpret certain keys.
2018-06-03 22:31:02 +02:00
b-r-o-c-k
90f9f8af6c deps: Ignore whitespace when applying libuv patch 2018-06-03 22:31:02 +02:00
b-r-o-c-k
f8eb5c83ed deps: Upgrade LuaRocks and remove patch 2018-06-03 22:31:01 +02:00