aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir/test_lambda.vim
Commit message (Collapse)AuthorAge
* vim-patch:8.1.0711: test files still use function!zeertzjq2022-02-07
| | | | | | | | Problem: Test files still use function!. Solution: Remove the exclamation mark. Fix overwriting a function. https://github.com/vim/vim/commit/1e1153600c0377472d62cc553173fe555ddcf5a7 Some of the changes were already applied previously.
* vim-patch:8.1.2412: crash when evaluating expression with error (#17109)zeertzjq2022-01-31
|
* fix(eval): cherry-pick emsg changes from v8.1.0736Sean Dewar2021-08-12
| | | | | | | | | | | v8.1.0736 made some changes for making some emsgs more specific. Includes the change for Test_lambda_fails() in test_lambda.vim. Adjust relevant functionaltests to expect the new emsgs. This patch has been fully ported in my Blob port PR, but it hasn't been merged yet, so just use what we need from it for now. Required for v8.1.1821.
* vim-patch:8.2.0499: calling a lambda is slower than evaluating a stringJan Edmund Lazo2020-09-30
| | | | | | | | | | Problem: Calling a lambda is slower than evaluating a string. Solution: Make calling a lambda faster. (Ken Takata, closes vim/vim#5727) https://github.com/vim/vim/commit/f10806b25090879fdc1a86cc0da2f4f34fd21921 Port "uf_flags" constants from patch 8.2.1054 to sync with Vim. Port user_func_error() from patch 8.2.0149. Port Test_lambda_scope() changes from patch 8.1.0736 so that it passes.
* vim-patch:8.1.1738: testing lambda with timer is slow (#10590)Daniel Hahler2019-07-24
| | | | | | Problem: Testing lambda with timer is slow. Solution: Do not test timer accuracy, only that it works. (Daniel Hahler, closes vim/vim#4723) https://github.com/vim/vim/commit/9bc4dde45d45df732953491d0f2c3fd3b10a627e
* vim-patch:8.1.0019: error when defining a Lambda with index of a function resultJan Edmund Lazo2019-03-15
| | | | | | | Problem: Error when defining a Lambda with index of a function result. Solution: When not evaluating an expression and skipping a function call, set the return value to VAR_UNKNOWN. https://github.com/vim/vim/commit/b4518563c73460150344a57879bf5b22cb8b1c77
* tests: load-adjust timer tests (oldtest)Marco Hinz2019-01-17
|
* test: adjust time-sensitive testsJustin M. Keyes2018-11-30
| | | | | | | | | | | | | | | | | | | | | From test_alot.vim: Found errors in Test_lambda_with_timer(): First run: function RunTheTest[35]..Test_lambda_with_timer line 19: Expected True but got 0 Second run: function RunTheTest[35]..Test_lambda_with_timer line 19: Expected True but got 0 previously: #9220 - Timer tests are less reliable on Travis CI macOS 10.12/10.13. ref #6829 ref e39dade80b02 ref de13113dc16e ref https://github.com/neovim/neovim/pull/9095#issuecomment-429603452 > We don't guarantee that a X ms timer is triggered during Y ms sleep > for any X<Y, though I would expect the load to be really bad for this > to happen with X=10ms, Y=40ms. - Call test_garbagecollect_now(), as Vim does.
* test: adjust time-sensitive tests (#9220)Justin M. Keyes2018-11-10
| | | | | | | | | | | | | - window_split_tab_spec.lua: Put cursor at bottom of :terminal buffer so that it follows output. - inccommand_spec.lua: Increase timeout to allow 2nd retry. - Timer tests are less reliable on Travis CI macOS 10.12/10.13. ref #6829 ref e39dade80b02 ref de13113dc16e ref https://github.com/neovim/neovim/pull/9095#issuecomment-429603452 > We don't guarantee that a X ms timer is triggered during Y ms sleep > for any X<Y, though I would expect the load to be really bad for this > to happen with X=10ms, Y=40ms.
* Allow lambdas to be used with jobs, timers and dictwatchers.Michael Ennen2017-02-14
|
* vim-patch:7.4.2137Michael Ennen2017-02-14
| | | | | | | | | Problem: Using function() with a name will find another function when it is redefined. Solution: Add funcref(). Refer to lambda using a partial. Fix several reference counting issues. https://github.com/vim/vim/commit/437bafe4c8a83ed71ee006eda7f54b65a90f0d4c
* vim-patch:7.4.2136Michael Ennen2017-02-14
| | | | | | | Problem: Closure function fails. Solution: Don't reset uf_scoped when it points to another funccal. https://github.com/vim/vim/commit/580164481924ed8611eb79f0247a0eb1ca0b3b9a
* vim-patch:7.4.2120Michael Ennen2017-02-14
| | | | | | | | Problem: User defined functions can't be a closure. Solution: Add the "closure" argument. Allow using :unlet on a bound variable. (Yasuhiro Matsumoto, Ken Takata) https://github.com/vim/vim/commit/10ce39a0d52272a3dfff2feb8c631529f29e6740
* vim-patch:7.4.2119Michael Ennen2017-02-14
| | | | | | | | Problem: Closures are not supported. Solution: Capture variables in lambdas from the outer scope. (Yasuhiro Matsumoto, Ken Takata) https://github.com/vim/vim/commit/1e96d9bf98f9ab84d5af7f98d6a961d91b17364f
* vim-patch:7.4.2076Michael Ennen2017-02-14
| | | | | | | Problem: Syntax error when dict has '>' key. Solution: Check for endchar. (Ken Takata) https://github.com/vim/vim/commit/4f0383bc3fe5af0229fb66b53fe94329af783eff
* vim-patch:7.4.2044Michael Ennen2017-02-14
| | | | | | | | Problem: filter() and map() either require a string or defining a function. Solution: Support lambda, a short way to define a function that evaluates an expression. (Yasuhiro Matsumoto, Ken Takata) https://github.com/vim/vim/commit/069c1e7fa9f45a665064f7f2c17da84d6a48f544
* vim-patch:7.4.1727Michael Ennen2017-02-14
Problem: Cannot detect a crash in tests when caused by garbagecollect(). Solution: Add garbagecollect_for_testing(). Do not free a job if is still useful. https://github.com/vim/vim/commit/ebf7dfa6f121c82f97d2adca3d45fbaba9ad8f7e