aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval.c
Commit message (Collapse)AuthorAge
...
* | Merge #10615 'vim-patch:8.1.0053'Justin M. Keyes2019-07-29
|\ \ | | | | | | fix #10604
| * | vim-patch:8.1.0053 use typval_T in the caller of call_vim_functioncangscop2019-07-29
| | | | | | | | | | | | | | | | | | Problem: unreliable types for complete function arguments Solution: fix argument type for functions w/ unreliable type conversion(Ozaki Kiichi) vim/vim#2993
| * | vim-patch:8.1.53 use typval_T in the caller of call_vim_functioncangscop2019-07-27
| | | | | | | | | | | | | | | | | | Problem: unreliable types for complete function arguments Solution: fix argument type for functions w/ unreliable type conversion(Ozaki Kiichi) vim/vim#2993
* | | clang/"dead assignments" #10620Bartosz Miera2019-07-29
| | | | | | | | | | | | Also revert possibly-wrong change in f_sign_getplaced() from 652be3cb0040.
* | | Merge #10643 from janlazo/vim-8.1.1765Justin M. Keyes2019-07-29
|\ \ \ | | | | | | | | vim-patch:8.1.{990,992,1765}
| * | | vim-patch:8.1.0990: floating point exception with "%= 0" and "/= 0"Jan Edmund Lazo2019-07-28
| | | | | | | | | | | | | | | | | | | | | | | | Problem: Floating point exception with "%= 0" and "/= 0". Solution: Avoid dividing by zero. (Dominique Pelle, closes vim/vim#4058) https://github.com/vim/vim/commit/e21c1580b7acb598a6e3c38565434fe5d0e2ad7a
| * | | vim-patch:8.1.1765: get(func, dict, def) does not work properlyJan Edmund Lazo2019-07-28
| | | | | | | | | | | | | | | | | | | | | | | | Problem: get(func, dict, def) does not work properly. Solution: Handle NULL dict better. (Takuya Fujiwara, closes vim/vim#4734) https://github.com/vim/vim/commit/f91aac5e3e3b8b1633d84eac2687ebbd76d8133b
* | | | PVS/V547: expression is always true/false #10640Ihor Antonov2019-07-29
|/ / / | | | | | | | | | Functions marked with FUNC_ATTR_NONNULL_RET do not return NULL. Remove redundant checks.
* | | vim-patch:8.0.1753: fix various warnings #10639Ihor Antonov2019-07-28
| | | | | | | | | | | | | | | | | | vim-patch:8.0.1753: various warnings from a static analyser Problem: Various warnings from a static analyser Solution: Remove unneeded conditions. https://github.com/vim/vim/commit/1c17ffa4611f4efe68c61f7cdd9ed692a866ba75
* | | API: Context: save/restoreAbdelhakeem2019-07-27
| | |
* | | eval: context: add ctx-family functionsAbdelhakeem2019-07-27
| | |
* | | API: ContextJustin M. Keyes2019-07-27
|/ /
* | cleanup: remove mch_fopen in favor of os_fopenJustin M. Keyes2019-07-25
| |
* | vim-patch:8.1.0899: no need to check restricted mode for setwinvar()Jan Edmund Lazo2019-07-24
| | | | | | | | | | | | Problem: No need to check restricted mode for setwinvar(). Solution: Remove check_restricted(). https://github.com/vim/vim/commit/e0fb7d1e38e1cf699412e212cda863420f5f8bd2
* | vim-patch:8.1.1740: exepath() doesn't work for "bin/cat" (#10556)Daniel Hahler2019-07-24
| | | | | | | | | | | | | | | | Problem: Exepath() doesn't work for "bin/cat". Solution: Check for any path separator. (Daniel Hahler, closes vim/vim#4724, closes vim/vim#4710) https://github.com/vim/vim/commit/d08b8c4c04db9433340df38d21f0e26878f28421 Fixes https://github.com/neovim/neovim/issues/10554.
* | os_can_exe: remove char_uJustin M. Keyes2019-07-21
| |
* | win: jobstart(), system(): $PATHEXT-resolve exeJustin M. Keyes2019-07-21
| | | | | | | | | | | | | | | | | | | | | | | | Windows: In order for jobstart(['foo']), system(['foo']) to find "foo.cmd", we must replace "foo" with "foo.cmd" before sending `argv` to process_spawn(). Rationale: jobstart([…]), system([…]) "executable" semantics should be consistent with the VimL executable() function. fix #9569 related: #10554
* | [RFC]vim-patch:8.1.{749,1715} #10545Jan Edmund Lazo2019-07-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * vim-patch:8.1.1715: emoji characters are seen as word characters for spelling Problem: Emoji characters are seen as word characters for spelling. (Gautam Iyer) Solution: Exclude class 3 from word characters. https://github.com/vim/vim/commit/06e6377009c5763639310fa3bf892dec27a63334 * vim-patch:8.1.0749: error message contains garbage Problem: Error message contains garbage. (Dominique Pelle) Solution: Use correct pointer to failed expression. https://github.com/vim/vim/commit/6acc79f5d4b9d5b02f4ab21ec885e68acc13a2e2
* | reltimefloat(): allow negative result #10544Justin M. Keyes2019-07-20
| | | | | | | | | | | | | | | | | | For "backwards" duration, reltimefloat() should return negative value like its counterpart reltimestr(). ref bab24a88ab48 ref 06af88cd72ea ref #10521 fix #10452
* | doc [ci skip] #10383Justin M. Keyes2019-07-19
| | | | | | | | - test/README.md: document luassert `TableFormatLevel` - CONTRIBUTING.md: absorb parts of the old "Development tips" wiki page
* | refactor: enable -Wconversion for ex_getln.cBjörn Linse2019-07-19
| |
* | vim-patch:8.1.0740: Tcl test fails (#10540)Jan Edmund Lazo2019-07-19
| | | | | | | | | | | | Problem: Tcl test fails. Solution: When the argument is empty don't give an error, instead rely on the error reporting higher up. https://github.com/vim/vim/commit/8309b0559da6e9a581a7816572594c90c2d7f942
* | jobstop(): close channel before process_stop() #10522Justin M. Keyes2019-07-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fix #9799 regression of #7081 Helped-by: Björn Linse <bjorn.linse@gmail.com> Problem: :UpdateRemotePlugins (which calls rpcstop()) sometimes crashes: remote/host: python3 host registered plugins [] nvim: ../src/nvim/event/wstream.c:78: _Bool wstream_write(Stream *, WBuffer *): Assertion `!stream->closed' failed. Aborted (core dumped) Order of events (channel 163, see logs below): 1. Channel's in-stream (0x2ba86c0) is **closed** by `f_rpcstop`..`process_stop`. 2. `receive_msgpack` parses the channel out-stream (0x2ba8860) 3. Invokes "nvim_command_output" API method. 4. Writes result to the **closed** in-stream => **abort** - af993da4351d (`receive_msgpack`) tried to hack around same/similar issue. - Hack was removed in 5215e3205a07. Solution: in jobstop(), close the channel before process_stop(). Log: DEBUG 2019-07-16T20:54:12.191 25159 stream_close:96: closing Stream: 0x2b01a90 DEBUG 2019-07-16T20:54:12.210 25159 process_spawn:124: new: pid=28407 argv=[/usr/bin/python3] DEBUG 2019-07-16T20:54:12.210 25159 rpc_start:72: rpc ch 163 in-stream=0x2ba86c0 out-stream=0x2ba8860 INFO 2019-07-16T20:54:12.210 25159 channel_create_event:199: new channel 163 (function <SNR>61_on_exit[4]..<SNR>60_job_exit_cb[101]..<SNR>60_decrement_job_count[8]..remote#host#UpdateRemotePlugins[6]..<SNR>31_RegistrationCommands[15]..remote#host#Require[10]..provider#pythonx#Require[13]..provider#Poll:3) : {"id": 163, "client": {}, "mode": "rpc", "stream": "job"} DEBUG 2019-07-16T20:54:12.211 25159 log_server_msg:729: RPC ->ch 163: [request] [0, 1, "poll", []] DEBUG 2019-07-16T20:54:12.355 25159 receive_msgpack:227: ch 163: parsing 21 bytes from msgpack Stream: 0x2ba8860 DEBUG 2019-07-16T20:54:12.355 25159 log_client_msg:766: RPC <-ch 163: [request] [0, 1, "vim_get_api_info", []] DEBUG 2019-07-16T20:54:12.355 25159 RPC: <-ch 163: invoke nvim_get_api_info DEBUG 2019-07-16T20:54:12.357 25159 log_server_msg:729: RPC ->ch 163: [response] [1, 1, nil, [163, {"version"=>{"major"=>0, "minor"=>4, }, ... DEBUG 2019-07-16T20:54:12.377 25159 receive_msgpack:227: ch 163: parsing 85 bytes from msgpack Stream: 0x2ba8860 DEBUG 2019-07-16T20:54:12.377 25159 log_client_msg:766: RPC <-ch 163: [request] [0, 2, "nvim_eval", ["((&number||&relativenumber) ? &numberwidth : 0) + &foldcolumn"]] DEBUG 2019-07-16T20:54:12.377 25159 handle_request:359: RPC: scheduled nvim_eval DEBUG 2019-07-16T20:54:12.377 25159 log_client_msg:766: RPC <-ch 163: [response] [1, 1, nil, "ok"] DEBUG 2019-07-16T20:54:12.378 25159 log_server_msg:729: RPC ->ch 163: [request] [0, 2, "specs", ["/home/vagrant/.config/nvim/rplugin/python3/__pycache__"]] DEBUG 2019-07-16T20:54:12.378 25159 RPC: <-ch 163: invoke nvim_eval DEBUG 2019-07-16T20:54:12.379 25159 log_server_msg:729: RPC ->ch 163: [response] [1, 2, nil, 0] DEBUG 2019-07-16T20:54:12.379 25159 receive_msgpack:227: ch 163: parsing 5 bytes from msgpack Stream: 0x2ba8860 DEBUG 2019-07-16T20:54:12.379 25159 log_client_msg:766: RPC <-ch 163: [response] [1, 2, nil, 0] DEBUG 2019-07-16T20:54:12.380 25159 log_server_msg:729: RPC ->ch 163: [request] [0, 3, "specs", ["/home/vagrant/.config/nvim/rplugin/python3/foo.py"]] DEBUG 2019-07-16T20:54:12.380 25159 receive_msgpack:227: ch 163: parsing 79 bytes from msgpack Stream: 0x2ba8860 DEBUG 2019-07-16T20:54:12.380 25159 log_client_msg:766: RPC <-ch 163: [request] [0, 3, "nvim_command", ["redir =>a |exe "sil sign place buffer=".bufnr('')|redir end"]] DEBUG 2019-07-16T20:54:12.381 25159 handle_request:359: RPC: scheduled nvim_command DEBUG 2019-07-16T20:54:12.381 25159 RPC: <-ch 163: invoke nvim_command DEBUG 2019-07-16T20:54:12.381 25159 log_server_msg:729: RPC ->ch 163: [response] [1, 3, nil, nil] DEBUG 2019-07-16T20:54:12.381 25159 receive_msgpack:227: ch 163: parsing 5 bytes from msgpack Stream: 0x2ba8860 DEBUG 2019-07-16T20:54:12.381 25159 log_client_msg:766: RPC <-ch 163: [response] [1, 3, nil, 0] DEBUG 2019-07-16T20:54:12.382 25159 stream_close:95: trace: log_callstack at /home/vagrant/neovim/build/../src/nvim/log.c:256 stream_close at /home/vagrant/neovim/build/../src/nvim/event/stream.c:95 stream_may_close at /home/vagrant/neovim/build/../src/nvim/event/stream.c:111 process_stop at /home/vagrant/neovim/build/../src/nvim/event/process.c:230 f_jobstop at /home/vagrant/neovim/build/../src/nvim/eval.c:12231 f_rpcstop at /home/vagrant/neovim/build/../src/nvim/eval.c:14533 call_func at /home/vagrant/neovim/build/../src/nvim/eval.c:6564 get_func_tv at /home/vagrant/neovim/build/../src/nvim/eval.c:6304 ex_call at /home/vagrant/neovim/build/../src/nvim/eval.c:2903 do_one_cmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:2249 do_cmdline at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:593 call_user_func at /home/vagrant/neovim/build/../src/nvim/eval.c:22666 call_func at /home/vagrant/neovim/build/../src/nvim/eval.c:6550 get_func_tv at /home/vagrant/neovim/build/../src/nvim/eval.c:6304 eval7 at /home/vagrant/neovim/build/../src/nvim/eval.c:4407 eval6 at /home/vagrant/neovim/build/../src/nvim/eval.c:4104 eval5 at /home/vagrant/neovim/build/../src/nvim/eval.c:3985 eval4 at /home/vagrant/neovim/build/../src/nvim/eval.c:3688 eval3 at /home/vagrant/neovim/build/../src/nvim/eval.c:3606 eval2 at /home/vagrant/neovim/build/../src/nvim/eval.c:3537 eval1 at /home/vagrant/neovim/build/../src/nvim/eval.c:3464 eval0 at /home/vagrant/neovim/build/../src/nvim/eval.c:3424 ex_let_const at /home/vagrant/neovim/build/../src/nvim/eval.c:1604 ex_let at /home/vagrant/neovim/build/../src/nvim/eval.c:1546 do_one_cmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:2249 do_cmdline at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:593 call_user_func at /home/vagrant/neovim/build/../src/nvim/eval.c:22666 call_func at /home/vagrant/neovim/build/../src/nvim/eval.c:6550 get_func_tv at /home/vagrant/neovim/build/../src/nvim/eval.c:6304 ex_call at /home/vagrant/neovim/build/../src/nvim/eval.c:2903 do_one_cmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:2249 do_cmdline at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:593 do_ucmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:5803 do_one_cmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:2243 do_cmdline at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:593 call_user_func at /home/vagrant/neovim/build/../src/nvim/eval.c:22666 call_func at /home/vagrant/neovim/build/../src/nvim/eval.c:6550 get_func_tv at /home/vagrant/neovim/build/../src/nvim/eval.c:6304 ex_call at /home/vagrant/neovim/build/../src/nvim/eval.c:2903 do_one_cmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:2249 do_cmdline at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:593 call_user_func at /home/vagrant/neovim/build/../src/nvim/eval.c:22666 call_func at /home/vagrant/neovim/build/../src/nvim/eval.c:6550 get_func_tv at /home/vagrant/neovim/build/../src/nvim/eval.c:6304 ex_call at /home/vagrant/neovim/build/../src/nvim/eval.c:2903 do_one_cmd at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:2249 do_cmdline at /home/vagrant/neovim/build/../src/nvim/ex_docmd.c:593 call_user_func at /home/vagrant/neovim/build/../src/nvim/eval.c:22666 call_func at /home/vagrant/neovim/build/../src/nvim/eval.c:6550 callback_call at /home/vagrant/neovim/build/../src/nvim/eval.c:17917 channel_callback_call at /home/vagrant/neovim/build/../src/nvim/channel.c:675 on_channel_event at /home/vagrant/neovim/build/../src/nvim/channel.c:581 multiqueue_process_events at /home/vagrant/neovim/build/../src/nvim/event/multiqueue.c:147 nv_event at /home/vagrant/neovim/build/../src/nvim/normal.c:7987 normal_execute at /home/vagrant/neovim/build/../src/nvim/normal.c:1133 state_enter at /home/vagrant/neovim/build/../src/nvim/state.c:73 normal_enter at /home/vagrant/neovim/build/../src/nvim/normal.c:462 main at /home/vagrant/neovim/build/../src/nvim/main.c:570 ?? ??:0 _start at ??:? DEBUG 2019-07-16T20:54:12.417 25159 stream_close:96: closing Stream: 0x2ba86c0 INFO 2019-07-16T20:54:12.417 25159 os_proc_tree_kill:96: sending SIGTERM to process group: -28407 DEBUG 2019-07-16T20:54:12.417 25159 receive_msgpack:227: ch 163: parsing 31 bytes from msgpack Stream: 0x2ba8860 DEBUG 2019-07-16T20:54:12.417 25159 log_client_msg:766: RPC <-ch 163: [request] [0, 4, "nvim_command_output", ["echo a"]] DEBUG 2019-07-16T20:54:12.417 25159 handle_request:359: RPC: scheduled nvim_command_output DEBUG 2019-07-16T20:54:12.424 25159 RPC: <-ch 163: invoke nvim_command_output DEBUG 2019-07-16T20:54:12.424 25159 log_server_msg:729: RPC ->ch 163: [response] [1, 4, [0, "Vim(echo):E121: Undefined variable: a"], nil] ERROR 2019-07-16T20:54:12.424 25159 wstream_write:78: xxx stream=0x2ba86c0 DEBUG 2019-07-16T20:54:12.425 25159 wstream_write:79: trace: log_callstack at /home/vagrant/neovim/build/../src/nvim/log.c:256 wstream_write at /home/vagrant/neovim/build/../src/nvim/event/wstream.c:82 channel_write at /home/vagrant/neovim/build/../src/nvim/msgpack_rpc/channel.c:407 request_event at /home/vagrant/neovim/build/../src/nvim/msgpack_rpc/channel.c:383 multiqueue_process_events at /home/vagrant/neovim/build/../src/nvim/event/multiqueue.c:147 nv_event at /home/vagrant/neovim/build/../src/nvim/normal.c:7987 normal_execute at /home/vagrant/neovim/build/../src/nvim/normal.c:1133 state_enter at /home/vagrant/neovim/build/../src/nvim/state.c:73 normal_enter at /home/vagrant/neovim/build/../src/nvim/normal.c:462 main at /home/vagrant/neovim/build/../src/nvim/main.c:570 ?? ??:0 _start at ??:?
* | viml/profile: revert proftime_T to unsigned type #10521Justin M. Keyes2019-07-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - reltimestr(): Produce negative value by comparing the unsigned proftime_T value to INT64_MAX. https://github.com/neovim/neovim/issues/10452#issuecomment-511155132 1. The interfaces of nearly all platforms return uint64_t. INT64_MAX is only half of that. 2. Low-level interfaces like this typically define that there is no fixed starting point. The only guarantees are that it's (a) monotonically increasing at a rate that (b) matches real time. ref 06af88cd72ea fix #10452
* | vim-patch:8.1.0583: using illogical name for get_dict_number()/get_dict_string()Jan Edmund Lazo2019-07-15
| | | | | | | | | | | | Problem: Using illogical name for get_dict_number()/get_dict_string(). Solution: Rename to start with dict_. https://github.com/vim/vim/commit/8f66717a1f835b8194139d158c1e2df8b30c3ef3
* | vim-patch:8.1.1012: memory leak with E461Jan Edmund Lazo2019-07-15
| | | | | | | | | | | | Problem: Memory leak with E461. Solution: Clear the typeval. (Dominique Pelle, closes vim/vim#4111) https://github.com/vim/vim/commit/ab89d7ab89a1dd7e40cc28df96c71c11b5ab9089
* | vim-patch:8.1.0495: :filter only supports some commandsJan Edmund Lazo2019-07-15
| | | | | | | | | | | | | | Problem: :filter only supports some commands. Solution: Add :filter support for more commands. (Marcin Szamotulski, closes vim/vim#2856) https://github.com/vim/vim/commit/f86db78fed78541cefdb706e4779ce5ae9ca7820
* | viml/profile: revert gettimeofday() #10488Justin M. Keyes2019-07-13
| | | | | | | | | | | | | | e2ce5ff9d616 was proven to be bogus, so revert it. close #10328 ref #10356 ref #10452
* | Merge #10435 from Shougo/vim-8.1.1610Justin M. Keyes2019-07-13
|\ \
| * | Fix lint failedShougo Matsushita2019-07-06
| | |
| * | Fix errorsShougo Matsushita2019-07-06
| | |
| * | vim-patch:8.1.1611: bufadd() reuses existing buffer without a nameShougo Matsushita2019-07-06
| | | | | | | | | | | | | | | | | | Problem: Bufadd() reuses existing buffer without a name. Solution: When the name is empty always create a new buffer. https://github.com/vim/vim/commit/892ae723ab95e429222e930cf41b32809567e58e
| * | vim-patch:8.1.1610: there is no way to add or load a buffer without side effectsShougo Matsushita2019-07-06
| | | | | | | | | | | | | | | | | | Problem: There is no way to add or load a buffer without side effects. Solution: Add the bufadd() and bufload() functions. https://github.com/vim/vim/commit/15e248e37f3925d430f96e945d52d3dc423cdc83
* | | vim-patch:8.1.1660: assert_fails() inside try/catch #10472Daniel Hahler2019-07-13
| | | | | | | | | | | | | | | Problem: Assert_fails() does not fail inside try/catch. Solution: Set trylevel to zero. (Ozaki Kiichi, closes vim/vim#4639) https://github.com/vim/vim/commit/7780e5c1c5485a979ab6e3914a43e17912e213a8
* | | eval.c: clang/"Dead assignment" #10446Bartosz Miera2019-07-09
| | |
* | | Merge #10394 from janlazo/vim-8.1.1614Justin M. Keyes2019-07-06
|\ \ \ | | | | | | | | vim-patch:8.1.{1614,1632,1634,1639}
| * | | vim-patch:8.1.1639: changing an autoload name into a file name is inefficientJan Edmund Lazo2019-07-05
| |/ / | | | | | | | | | | | | | | | Problem: Changing an autoload name into a script file name is inefficient. Solution: Remember the last replaced #. (Ozaki Kiichi, closes vim/vim#4618) https://github.com/vim/vim/commit/28fc247f8d94a1cfabbcf2691ca942bde96f6d2f
* / / func_clear_items: use XFREE_CLEAR #10436Daniel Hahler2019-07-06
|/ / | | | | Follow-up to https://github.com/neovim/neovim/pull/10428#discussion_r300813498
* | vim-patch:8.1.0229: crash when dumping profiling data #10428Daniel Hahler2019-07-05
| | | | | | | | | | Problem: Crash when dumping profiling data. Solution: Reset flag indicating that initialization was done. https://github.com/vim/vim/commit/79c2ad50b8069bbb3281bcabe412bd6641756724
* | viml/profile: switch to uv_gettimeofday() #10356Justin M. Keyes2019-06-29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Performance of high-resolution time (clock_gettime via uv_hrtime) is expensive on some systems. For profiling VimL, syntax, etc., we don't care about nanosecond-precision and monotonicity edge-cases, so avoid uv_hrtime(). closes #10328 From the uv__hrtime() source: https://github.com/libuv/libuv/blob/0cdb4a5b4b706d0e09413d9270da28f9a88dc083/src/unix/linux-core.c#L442-L462 /* Prefer CLOCK_MONOTONIC_COARSE if available but only when it has * millisecond granularity or better. CLOCK_MONOTONIC_COARSE is * serviced entirely from the vDSO, whereas CLOCK_MONOTONIC may * decide to make a costly system call. */ This micro-benchmark (Debug build) shows negligible differences on my system: #include <sys/time.h> ... proftime_T tm = profile_start(); int trials = 999999; int64_t t = 0; struct timeval tv; for (int i = 0; i < trials; i++) { t += gettimeofday(&tv,NULL); } tm = profile_end(tm); ILOG("%d trials of gettimeofday: %s", trials, profile_msg(tm)); tm = profile_start(); for (int i = 0; i < trials; i++) { t += os_hrtime(); } tm = profile_end(tm); ILOG("%d trials of os_hrtime: %s", trials, profile_msg(tm)); tm = profile_start(); for (int i = 0; i < trials; i++) { t += os_utime(); } tm = profile_end(tm); ILOG("%d trials of os_utime: %s", trials, profile_msg(tm)); ILOG("%zu", t);
* | eval/api: don't allow the API to be called in the sandbox.Björn Linse2019-06-26
| | | | | | | | | | Identifying and maintaining a "secure" subset of the API would be too much busywork. So just disable the entire thing.
* | Merge #10250 from blueyed/vim-8.0.1039Justin M. Keyes2019-06-25
|\ \ | | | | | | vim-patch:8.0.{10{39,53,55},1274}: cannot change a line in not current buffer
| * | vim-patch:8.0.1274: setbufline() fails when using foldingDaniel Hahler2019-06-18
| | | | | | | | | | | | | | | | | | Problem: setbufline() fails when using folding. Solution: Set "curwin" if needed. (Ozaki Kiichi, closes vim/vim#2293) https://github.com/vim/vim/commit/0c4dc88a637a5027209aa00226996af84e248636
| * | vim-patch:8.0.1053: setline() does not work on startupDaniel Hahler2019-06-18
| | | | | | | | | | | | | | | | | | | | | Problem: setline() does not work on startup. (Manuel Ortega) Solution: Do not check for ml_mfp to be set for the current buffer. (Christian Brabandt) https://github.com/vim/vim/commit/9d954207e2cc807b475bb04f8b59ef5bb3772d99
| * | vim-patch:8.0.1039: cannot change a line in not current bufferDaniel Hahler2019-06-17
| | | | | | | | | | | | | | | | | | Problem: Cannot change a line in a buffer other than the current one. Solution: Add setbufline(). (Yasuhiro Matsumoto, Ozaki Kiichi, closes vim/vim#1953) https://github.com/vim/vim/commit/b31cf2bb0be95d106bd8eef93cc07550591c1d0d
* | | Merge #10313 from rhysd/const-patchesJustin M. Keyes2019-06-24
|\ \ \ | | | | | | | | vim-patch:8.1.1539,8.1.1543,8.1.1554 for :const from Vim
| * | | eval.c: Fix clint errors and typo in comment of ex_const()rhysd2019-06-24
| | | |
| * | | vim-patch:8.1.1539: not easy to define a variable and lock itrhysd2019-06-24
| | | | | | | | | | | | | | | | | | | | | | | | Problem: Not easy to define a variable and lock it. Solution: Add ":const". https://github.com/vim/vim/commit/9937a055437ef67b57a1bdec8f0799b669c9dbf0
* | | | eval: assert VAR_LIST branch in filter_map()Jan Edmund Lazo2019-06-23
| | | |
* | | | vim-patch:8.1.0747: map() with a bad expression doesn't give an errorJan Edmund Lazo2019-06-23
| | | | | | | | | | | | | | | | | | | | | | | | Problem: map() with a bad expression doesn't give an error. (Ingo Karkat) Solution: Check for giving an error message. (closes vim/vim#3800) https://github.com/vim/vim/commit/ce9d50df07402cb8e196537a9c4505845adecabc