aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_editor.lua
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2025-12-16 08:13:18 +0800
committerzeertzjq <zeertzjq@outlook.com>2025-12-17 06:47:34 +0800
commit6061169183c02e6e6cabae09a56dd68989afe257 (patch)
tree9debc630e24cd58b0c590243f65a3cb147a532dc /runtime/lua/vim/_editor.lua
parent53fd3657ccf50046f095e90f44ef4c34e2e2f6d5 (diff)
downloadrneovim-6061169183c02e6e6cabae09a56dd68989afe257.tar.gz
rneovim-6061169183c02e6e6cabae09a56dd68989afe257.tar.bz2
rneovim-6061169183c02e6e6cabae09a56dd68989afe257.zip
vim-patch:9.1.1983: Vim9: class_name definition can be improved
Problem: Vim9: class_name definition can be improved Solution: Use string_T to store class_name, avoid using STRLEN() calls, simplify code, remove unused definition of struct oc_newmember_S (John Marriott) Use struct string_T to store the field class_name in struct class_T, which means we can just use the .length field in struct string_T instead of measuring it. In addition: 1. In eval.c use string_T to store class_name and s in function class_tv2string(). 2. In vim9type.c change some calls from ga_concat() to ga_concat_len() where the length is known. 3. In vim9class.c remove unused struct definition oc_newmember_S. Change some calls from ga_concat() to ga_concat_len() where the length is known. 4. In scriptfile.c use string_T to store type_name, class_name and es_name in function estack_sfile(). 5. In function estack_sfile() simplify construction of the grow array ga and change some calls from ga_concat() to ga_concat_len() when the length is known. closes: vim/vim#18925 https://github.com/vim/vim/commit/2019321e0be320183afa47b7ea979dc4fc3984a0 Co-authored-by: John Marriott <basilisk@internode.on.net>
Diffstat (limited to 'runtime/lua/vim/_editor.lua')
0 files changed, 0 insertions, 0 deletions