zeertzjq
fa12b9ca2b
vim-patch:partial:9.0.1237: code is indented more than necessary ( #21971 )
...
Problem: Code is indented more than necessary.
Solution: Use an early return where it makes sense. (Yegappan Lakshmanan,
closes vim/vim#11858 )
6ec6666047
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com >
2023-01-24 08:43:51 +08:00
zeertzjq
d58bf4ff30
perf(completion): use one call to globpath() for .vim and .lua #21942
...
Test using the following test script (timings with ASAN):
let start = reltime()
for i in range(100)
call getcompletion('', 'filetype')
endfor
echomsg reltimefloat(reltime(start))
Without this PR: 3.251825 seconds
With this PR: 2.747285 seconds
2023-01-23 02:42:37 -08:00
zeertzjq
18fb669b9b
fix(completion): include lua syntaxes in :ownsyntax completion ( #21941 )
...
This just removes DIP_LUA and always executes its branches.
Also add tests for cmdline completion for other lua runtime files.
2023-01-22 11:19:58 +08:00
dundargoc
2c1e7242f9
refactor: replace char_u with char 23 ( #21798 )
...
Work on https://github.com/neovim/neovim/issues/459
2023-01-18 18:52:19 +08:00
zeertzjq
3db2139195
vim-patch:8.2.4617: no completion for :scriptnames
...
Problem: No completion for :scriptnames.
Solution: Implement :scriptnames completion. (Yegappan Lakshmanan,
closes vim/vim#10005 )
454ce6737c
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com >
2023-01-17 20:26:06 +08:00
dundargoc
3269902a13
refactor: fix IWYU mapping file and use IWYU ( #21802 )
...
Also add the EXITFREE definition to main_lib rather than the nvim target, as the header generation needs the EXITFREE flag to work properly.
2023-01-15 14:16:33 +01:00
dundargoc
50f03773f4
refactor: replace char_u with char 18 ( #21237 )
...
refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
2023-01-09 22:37:34 +08:00
dundargoc
1492094003
refactor: replace char_u with char 17 - remove STRLCPY ( #21235 )
...
refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
2023-01-09 21:13:06 +08:00
dundargoc
3b96ccf7d3
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-11-28 14:53:35 +01:00
Dundar Göc
bd22585061
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-11-26 15:52:21 +01:00
Dundar Göc
40f3f75867
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-11-19 16:27:10 +01:00
Gregory Anders
6d9c3d903e
refactor: deprecate 'secure' option
...
Now that 'exrc' files must be explicitly marked trusted there is no need
to constrain what can be done in them.
2022-11-17 08:23:41 -07:00
dundargoc
66360675cf
build: allow IWYU to fix includes for all .c files
...
Allow Include What You Use to remove unnecessary includes and only
include what is necessary. This helps with reducing compilation times
and makes it easier to visualise which dependencies are actually
required.
Work on https://github.com/neovim/neovim/issues/549 , but doesn't close
it since this only works fully for .c files and not headers.
2022-11-15 10:30:03 +01:00
dundargoc
4716a578ae
docs: fix typos
2022-11-02 21:45:26 +08:00
dundargoc
784e498c4a
refactor: clang-tidy fixes to silence clangd warning ( #20683 )
...
* refactor: readability-uppercase-literal-suffix
* refactor: readability-named-parameter
* refactor: bugprone-suspicious-string-compare
* refactor: google-readability-casting
* refactor: readability-redundant-control-flow
* refactor: bugprone-too-small-loop-variable
* refactor: readability-non-const-parameter
* refactor: readability-avoid-const-params-in-decls
* refactor: google-readability-todo
* refactor: readability-inconsistent-declaration-parameter-name
* refactor: bugprone-suspicious-missing-comma
* refactor: remove noisy or slow warnings
2022-10-21 20:47:44 +08:00
dundargoc
6d557e324f
vim-patch:8.1.0941: macros for MS-Windows are inconsistent ( #20215 )
...
Problem: Macros for MS-Windows are inconsistent, using "32", "3264 and
others.
Solution: Use MSWIN for all MS-Windows builds. Use FEAT_GUI_MSWIN for the
GUI build. (Hirohito Higashi, closes vim/vim#3932 )
4f97475d32
2022-09-18 09:17:15 +08:00
Dundar Göc
3ff46544c9
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-09-11 13:28:59 +02:00
Dundar Göc
684bc749ef
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-09-10 11:17:40 +02:00
Dundar Göc
c5322e752e
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-09-09 21:02:42 +02:00
Dundar Göc
fb1edb2f57
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-08-31 13:47:18 +02:00
dundargoc
2828aae7b4
refactor: replace char_u with char 4 ( #19987 )
...
* refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
2022-08-30 14:52:09 +02:00
Dundar Göc
58f30a326f
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-08-29 15:48:56 +02:00
Dundar Göc
691f4715c0
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-08-27 17:59:43 +02:00
Dundar Göc
3952770360
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-08-26 22:24:28 +02:00
zeertzjq
64d147b471
vim-patch:9.0.0248: duplicate code in finding a script in the execution stack ( #19917 )
...
Problem: Duplicate code in finding a script in the execution stack.
Solution: Reduce duplicate code. (closes vim/vim#10961 )
a247142ae4
2022-08-24 06:28:37 +08:00
zeertzjq
d0b9fe2d5a
vim-patch:8.2.4749: <script> is not expanded in autocmd context
...
Problem: <script> is not expanded in autocmd context.
Solution: Add the context to the pattern struct. (closes vim/vim#10144 )
Rename AutoPatCmd to AutoPatCmd_T.
eca7c60d68
Omit AutoPatCmd -> AutoPatCmd_T rename as it is inconsistent.
Use `.sn_name` instead of `->sn_name` as v8.2.0154 hasn't been ported.
Omit acp_script_stx(), use member directly.
2022-08-23 17:48:12 +08:00
zeertzjq
ffa1335047
vim-patch:8.2.4726: cannot use expand() to get the script name
...
Problem: Cannot use expand() to get the script name.
Solution: Support expand('<script>'). (closes vim/vim#10121 )
6013d0045d
Use `.sn_name` instead of `->sn_name` as v8.2.0154 hasn't been ported.
Cherry-pick builtin.txt expand() doc from latest Vim.
2022-08-23 17:47:46 +08:00
zeertzjq
2bed0d1d97
vim-patch:8.2.4753: error from setting an option is silently ignored ( #19888 )
...
Problem: Error from setting an option is silently ignored.
Solution: Handle option value errors better. Fix uses of N_().
31e5c60a68
2022-08-22 13:56:50 +08:00
zeertzjq
0d0a336c53
vim-patch:8.1.1886: command line expansion code is spread out ( #19861 )
...
Problem: Command line expansion code is spread out.
Solution: Move the code to cmdexpand.c. (Yegappan Lakshmanan, closes vim/vim#4831 )
66b51420e0
2022-08-21 06:33:24 +08:00
zeertzjq
d1464d16d6
fix(source): fix expand('<sfile>') no longer works for Lua
2022-08-16 05:39:44 +08:00
zeertzjq
1d28bbf1e5
vim-patch:9.0.0217: 'shellslash' works differently when sourcing a script again
...
Problem: 'shellslash' works differently when sourcing a script again.
Solution: Use the name from the script item. (closes vim/vim#10920 )
5a4fff4d94
2022-08-16 05:39:12 +08:00
zeertzjq
9ab9eb1220
fix(source): make changing 'shellslash' change expand() result
2022-08-15 10:14:53 +08:00
zeertzjq
d6a6adf708
vim-patch:8.2.1658: expand('<stack>') has trailing ".."
...
Problem: Expand('<stack>') has trailing "..".
Solution: Remove the "..". (closes vim/vim#6927 )
a810db3f17
2022-08-15 10:14:53 +08:00
zeertzjq
ed65724e57
vim-patch:8.2.1653: expand('<stack>') does not include the final line number
...
Problem: Expand('<stack>') does not include the final line number.
Solution: Add the line nuber. (closes vim/vim#6927 )
4f25b1aba0
2022-08-15 10:14:53 +08:00
zeertzjq
98ab0bb5f7
vim-patch:8.2.1297: when a test fails it's often not easy to see where
...
Problem: When a test fails it's often not easy to see what the call stack
is.
Solution: Add more entries from the call stack in the exception message.
a5d0423fa1
Use docs from latest Vim.
2022-08-15 10:14:52 +08:00
zeertzjq
1ca2247639
vim-patch:8.2.0823: Vim9: script reload test is disabled
...
Problem: Vim9: script reload test is disabled.
Solution: Compile a function in the context of the script where it was
defined. Set execution stack for compiled function. Add a test
that an error is reported for the right file/function.
25e0f5863e
Omit stack_top_is_ufunc(): only used by Vim9 script.
2022-08-14 04:29:44 +08:00
zeertzjq
ded2925b40
refactor: change remaining sourcing_name/sourcing_lnum to exestack
...
Co-Authored-By: VVKot <volodymyr.kot.ua@gmail.com >
2022-08-14 04:29:44 +08:00
zeertzjq
f52c236c5b
vim-patch:8.2.0056: execution stack is incomplete and inefficient
...
Problem: Execution stack is incomplete and inefficient.
Solution: Introduce a proper execution stack and use it instead of
sourcing_name/sourcing_lnum. Create a string only when used.
1a47ae32cd
Omit test_debugger.vim: superseded by later patches.
Omit check_map_keycodes(): N/A.
Omit kword_test.c: N/A (converted to a unit test).
2022-08-14 04:29:44 +08:00
zeertzjq
342d18b91e
refactor: remove some unused includes ( #19740 )
...
Mostly avoids including eval.h, ex_cmds2.h and ex_docmd.h in other
headers.
2022-08-12 21:16:28 +08:00
Dundar Goc
094cdf2d69
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-08-12 14:22:02 +02:00
zeertzjq
f79773a3b4
refactor: move non-symbols in ex_eval.h to ex_eval_defs.h ( #19739 )
...
This avoids including ex_eval.h in any other header, thus preventing
future circular includes.
2022-08-12 19:16:24 +08:00
zeertzjq
103f10d901
refactor: move code dealing with script files to runtime.c ( #19734 )
...
vim-patch:8.1.1927: code for dealing with script files is spread out
Problem: Code for dealing with script files is spread out.
Solution: Move the code to scriptfile.c. (Yegappan Lakshmanan, closes vim/vim#4861 )
307c5a5bb7
2022-08-12 15:41:43 +08:00
zeertzjq
c7ca94ba7f
vim-patch:8.1.1684: profiling functionality is spread out
...
Problem: Profiling functionality is spread out.
Solution: Put profiling functionality in profiling.c. (Yegappan Lakshmanan,
closes vim/vim#4666 )
fa55cfc69d
Move proftime_T to types.h for now to avoid recursive #include.
2022-08-12 13:44:37 +08:00
Dundar Goc
824a729628
refactor: replace char_u with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-07-31 00:52:59 +02:00
Dundar Goc
3b8804571c
refactor: replace char_u
...
Work on https://github.com/neovim/neovim/issues/459
2022-07-02 16:01:27 +02:00
Thomas Vigouroux
fd3008a6ae
fix(coverity/348313): don't exit too early in runtime_default
2022-06-24 09:41:13 +02:00
dundargoc
9fec6dc9a2
refactor(uncrustify): set maximum number of consecutive newlines to 2 ( #18695 )
2022-05-25 12:31:14 -06:00
Dundar Goc
e31b32a293
refactor: replace char_u variables and functions with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-05-09 10:03:29 +02:00
Dundar Goc
5576d30e89
refactor: replace char_u variables and functions with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-05-04 15:25:54 +02:00
Dundar Goc
b9bdd0f61e
refactor: replace char_u variables and functions with char
...
Work on https://github.com/neovim/neovim/issues/459
2022-05-03 10:33:40 +02:00