aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval.c
Commit message (Collapse)AuthorAge
...
| * keymap: Make replace_termcodes and friends accept length and cpo_flagsZyX2016-04-18
| | | | | | | | | | | | | | Reasons: - One does not have to do `s[len] = NUL` to work with these functions if they do not need to replace the whole string: thus `s` may be const. - One does not have to save/restore p_cpo to work with them.
* | Merge pull request #4325 from watiko/vim-7.4.984Justin M. Keyes2016-04-25
|\ \ | | | | | | vim-patch:7.4.{984,1093}
| * | vim-patch:7.4.1093watiko2016-03-02
| | | | | | | | | | | | | | | | | | | | | | | | Problem: Typo in test goes unnoticed. Solution: Fix the typo. Give error for wrong arguments to cursor(). (partly by Hirohito Higashi) Add a test for cursor(). https://github.com/vim/vim/commit/24c4d539eed33e8073f8f9fe2bee497bbba935a4
| * | vim-patch:7.4.984watiko2016-03-02
| | | | | | | | | | | | | | | | | | | | | | | | Problem: searchpos() always starts searching in the first column, which is not what some people expect. (Brett Stahlman) Solution: Add the 'z' flag: start at the specified column. https://github.com/vim/vim/commit/ad4d8a192abf44b89371af87d70b971cd654b799
* | | Merge #4303 'vim-patch:7.4.{951,1143,1144}'.Justin M. Keyes2016-04-25
|\ \ \
| * | | vim-patch:7.4.1143watiko2016-03-02
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Can't sort on floating point numbers. Solution: Add the "f" flag to ":sort". (Alex Jakushev) Also add the "f" flag to sort(). https://github.com/vim/vim/commit/f7edf40448a09e04eec3bd05e043f7fea93b07c9
| * | | vim-patch:7.4.951watiko2016-03-02
| |/ / | | | | | | | | | | | | | | | | | | Problem: Sorting number strings does not work as expected. (Luc Hermitte) Solution: Add the 'N" argument to sort() https://github.com/vim/vim/commit/b00da1d6d1655cb6e415f84ecc3be5ff3b790811
* | | Merge pull request #4367 from jbradaric/vim-7.4.1107Justin M. Keyes2016-04-22
|\ \ \ | | | | | | | | vim-patch:7.4.{1107,1114,1116,1117,1120}
| * | | Merge tempfile.c back into fileio.cJurica Bradaric2016-04-20
| | | |
| * | | vim-patch:7.4.1107Jurica Bradaric2016-04-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Problem: Vim can create a directory but not delete it. Solution: Add an argument to delete() to make it possible to delete a directory, also recursively. https://github.com/vim/vim/commit/da440d21a6b94d7f525fa7be9b1417c78dd9aa4c
* | | | Merge #3229 ':tcd'Justin M. Keyes2016-04-21
|\ \ \ \
| * | | | tcd: doc, error messagesJustin M. Keyes2016-04-21
| | | | |
| * | | | Implement tab-local working directory feature.HiPhish2016-04-20
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New ex commands: 'tcd', 'tchdir' Changed Vimscript functions: 'haslocaldir', 'getcwd' The ex-commands ':tcd' and ':tchdir' are the tab-local equivalents of ':lcd' and ':lchdir'. There are no new Vimscript functions introduced, instead the functions 'haslocaldir' and 'getcwd' take in optional arguments. See the documentation for details Since there is now different levels of local directory a simple boolean at source level is no longer sufficient; a new enumeration type is used for the scope-level from now on. The documentation has been accommodated for these new commands and functional tests have been written to test the feature.
* / / / eval: let getreg() return valid list for an undefined registerBjörn Linse2016-04-21
|/ / / | | | | | | | | | | | | vim-patch:7.4.1755 this prevents a crash when the list is used in setreg() later
* | | Merge pull request #4589 from gregorias/patch_1113Justin M. Keyes2016-04-20
|\ \ \ | | | | | | | | vim-patch: 7.4.1113
| * | | vim-patch:7.4.1113Grzegorz Milka2016-04-19
| | | | | | | | | | | | | | | | | | | | Problem: Using {ns} in variable name does not work. (lilydjwg) Solution: Fix recognizing colon. Add a test.
* | | | v:windowid #4608Rui Abreu Ferreira2016-04-19
|/ / / | | | | | | | | | | | | | | | Set v:windowid as writeable (but read only in the sandbox). References #3626
* | | *: Fix preincrement lint errorsZyX2016-04-18
| | |
* | | eval/encode: Make sure that encoder can encode NULL variablesZyX2016-04-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | Adds two undocumented v: variables: _null_list and _null_dict because I do not know a reproducible way to get such lists (though I think I heard about this) and dictionaries (do not remember hearing about them). NULL strings are obtained using $XXX_UNEXISTENT_VAR_XXX. Fixes crash in json_encode($XXX_UNEXISTENT_VAR_XXX). Other added tests worked fine before this commit.
* | | *: Make set_vim_var_\* functions have proper argument typesZyX2016-04-18
| | |
* | | eval: Treat [] and [""] as any other empty stringZyX2016-04-18
| | |
* | | eval: Fix overflow in error message in f_json_decodeZyX2016-04-18
| | |
* | | eval: Remove assert expressionZyX2016-04-18
| | | | | | | | | | | | | | | GCC on travis thinks that 1. It is not constant. 2. Left-hand operand of comma has no effect (-Werror=unused-variable).
* | | eval: Do not break when VimVarIndex and vimvars order mismatchesZyX2016-04-18
| | | | | | | | | | | | Also makes sure that compiler will error out when new name is longer then vv_filler.
* | | eval: Rename json* functions to json_*ZyX2016-04-18
| | |
* | | api: Replace set_var(name, NIL) with del_var(name)ZyX2016-04-18
| | |
* | | eval: Fix QuickBuild failuresZyX2016-04-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Compiler used by one VM in QuickBuild has found a number of false positives. Everything is fine on travis. List of failures: From [QuickBuild][1], build [7429][2]: 14:38:19,945 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c: In function ‘assert_bool’: 14:38:19,945 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c:7551:40: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] 14:38:20,058 WARN - cc1: all warnings being treated as errors . This is not making much sense (7551:40 is `!=` in `{SpecialVarValue} != ({bool}?{SpecialVarValue}:{SpecialVarValue})`), but this error is present. --- Also fail from [build][3] [4930][4]: 15:47:00,853 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval/encode.c: In function ‘encode_read_from_list’: 15:47:00,853 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval/encode.c:258:30: error: conversion to ‘char’ from ‘int’ may alter its value [-Werror=conversion] , pointing to `:` in `{char} = ({char} == {const} ? {const} : {char})` where `{const}` is character constant like `'\n'`. I have no idea where exactly it saw conversion, so simply casted everything to (char). --- [Build][5] error: 08:32:03,472 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c: In function ‘tv_equal’: 08:32:03,472 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c:5077:1: error: control reaches end of non-void function [-Werror=return-type] --- Build [4949][7]: 11:28:00,578 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c: In function ‘f_type’: 11:28:00,578 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c:16085:24: error: ‘n’ may be used uninitialized in this function [-Werror=uninitialized] 11:28:00,581 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c: In function ‘f_empty’: 11:28:00,581 WARN - /home/quickbuild/buildagent/workspace/root/neovim/pull-requests-automated/src/nvim/eval.c:8505:24: error: ‘n’ may be used uninitialized in this function [-Werror=uninitialized] [1]: http://neovim-qb.szakmeister.net/wicket/page?5-1.ILinkListener-content-buildTab-panel-masterStep-body-children-0-step-body-children-2-body-children-3-step-body-children-0-step-body-children-0-step-head-logLink [2]: http://neovim-qb.szakmeister.net/build/4929 [3]: http://neovim-qb.szakmeister.net/build/4930 [4]: http://neovim-qb.szakmeister.net/wicket/page?1-1.ILinkListener-content-buildTab-panel-masterStep-body-children-0-step-body-children-1-body-children-3-step-body-children-0-step-body-children-0-step-head-logLink [5]: http://neovim-qb.szakmeister.net/build/4948/step_status [7]: http://neovim-qb.szakmeister.net/build/4949
* | | eval: Port parts of 7.4.1267 that are not already presentZyX2016-04-18
| | |
* | | eval: Make assert_true and assert_false accept v:true and v:falseZyX2016-04-18
| | |
* | | *: Fix linter errorsZyX2016-04-18
| | |
* | | eval: Remove v:noneZyX2016-04-18
| | | | | | | | | | | | | | | To get v:none back just rever this commit. This will not make json*() functions compatible with Vim though.
* | | eval: Remove get_vim_var_tv functionZyX2016-04-18
| | |
* | | eval: Move some decoding functions to eval/decode.cZyX2016-04-18
| | |
* | | eval: Get rid of VV_LEN constantZyX2016-04-18
| | |
* | | eval: Move encode.c to eval/encode.cZyX2016-04-18
| | |
* | | eval: Add jsondecode() functionZyX2016-04-18
| | |
* | | eval: Add special variables v:false, v:null, v:noneZyX2016-04-18
| | |
* | | eval: Add special variable typeZyX2016-04-18
| | |
* | | eval: Add jsonencode() functionZyX2016-04-18
| | | | | | | | | Ref #3471
* | | eval: Split out typval_T dumping functions to nvim/encode.cZyX2016-04-18
| |/ |/|
* | eval.c: Fix heap corruption error when constructing sourcing_nameoni-link2016-04-17
| | | | | | | | | | | | | | | | | | A wrong format specifier and not enough allocated memory for sourcing_name could lead to a heap corruption. Original patch by Rui Abreu Ferreira (@equalsraf) Fixes #4582
* | eval.c: Fix cut off of terminal exit messageoni-link2016-04-17
| | | | | | | | | | The message array in on_process_exit() is too short for a status > 99.
* | Merge pull request #4357 from jbradaric/vim-7.4.1105Justin M. Keyes2016-04-09
|\ \ | | | | | | vim-patch:7.4.1105
| * | eval: Fix linter error.Jurica Bradaric2016-02-27
| | |
| * | vim-patch:7.4.1105Jurica Bradaric2016-02-27
| | | | | | | | | | | | | | | | | | | | | Problem: When using slices there is a mixup of variable name and namespace. Solution: Recognize variables that can't be a namespace. (Hirohito Higashi) https://github.com/vim/vim/commit/9bbf63dbf8286fadc0cd6b3428010abb67b1b64d
* | | vim-patch:7.4.1654James McCoy2016-03-30
| | | | | | | | | | | | | | | | | | | | | Problem: Crash when using expand('%:S') in a buffer without a name. Solution: Don't set a NUL. (James McCoy, closes vim/vim#714) https://github.com/vim/vim/commit/52c6eaffd43a8c8865f8d6ed7cde0a8b137479e2
* | | vim-patch:7.4.1643James McCoy2016-03-30
| | | | | | | | | | | | | | | | | | | | | Problem: Terminating file name has side effects. Solution: Restore the character. (mostly by James McCoy, closes vim/vim#713) https://github.com/vim/vim/commit/d4caf5c16a9f1c9477d426e58d8d3dc47ab5f066
* | | vim-patch:7.4.1641James McCoy2016-03-30
| | | | | | | | | | | | | | | | | | | | | Problem: Using unterminated string. Solution: Add NUL before calling vim_strsave_shellescape(). (James McCoy) https://github.com/vim/vim/commit/5ca84ce4aa2832041f843e624c222bbc1f4d3e14
* | | Proper type checking for set{qf,loc}list()Marco Hinz2016-03-02
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | Prior to this change, type errors were silently ignored. They're explicit now. setqflist(list, action, title) setloclist(win, list, action, title) "list" (required) must be a list. "action" (optional) must a string. "title" (optional) must a string or number that gets converted to a string. An error is thrown otherwise.
* | Correct max numbers of args for some functionsMarco Hinz2016-03-01
| | | | | | | | Closes #3650.