mirror of
https://github.com/neovim/neovim.git
synced 2024-12-19 10:45:16 -07:00
29ded88957
Problem: The way option scopes currently work is inflexible and does not allow for nested option scopes or easily finding the value of an option at any arbitrary scope without having to do long handwritten switch-case statements like in `get_varp()`. `.indir` is also confusing and redundant since option indices for each scope can be autogenerated. Solution: Expand option scopes in such a way that an option can support any amount of scopes using a set of scope flags, similarly to how it's already done for option types. Also make options contain information about its index at each scope it supports. This allows for massively simplifying `get_varp()` and `get_varp_scope()` in the future by just using a struct for options at each scope. This would be done by creating a table that stores the offset of an option's variable at a scope by using the option's index at that scope as a key. This PR also autogenerates enums for option indices at each scope to remove the need for `.indir` entirely, and also to allow easily iterating over options all options that support any scope. Ref: #29314 |
||
---|---|---|
.. | ||
bump_deps.lua | ||
cdoc_grammar.lua | ||
cdoc_parser.lua | ||
check_urls.vim | ||
cliff.toml | ||
download-unicode-files.sh | ||
gen_eval_files.lua | ||
gen_filetype.lua | ||
gen_help_html.lua | ||
gen_lsp.lua | ||
gen_vimdoc.lua | ||
genappimage.sh | ||
lintcommit.lua | ||
lintdoc.lua | ||
luacats_grammar.lua | ||
luacats_parser.lua | ||
release.sh | ||
shadacat.py | ||
update_terminfo.sh | ||
util.lua | ||
vim-patch.sh | ||
vimpatch.lua | ||
windows.ti |