Mercurial > vim
annotate src/proto/dict.pro @ 31819:aec031683d61 v9.0.1242
patch 9.0.1242: code for :runtime completion is not consistent
Commit: https://github.com/vim/vim/commit/b0d45ec67f4976318f199a7929ad3bcf93686fd0
Author: zeertzjq <zeertzjq@outlook.com>
Date: Wed Jan 25 15:04:22 2023 +0000
patch 9.0.1242: code for :runtime completion is not consistent
Problem: Code for :runtime completion is not consistent.
Solution: Make code for cmdline expansion more consistent. (closes https://github.com/vim/vim/issues/11875)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 25 Jan 2023 16:15:06 +0100 |
parents | 684e6dfa2fba |
children | 02fe9a889b04 |
rev | line source |
---|---|
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
1 /* dict.c */ |
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
2 dict_T *dict_alloc(void); |
15016
c338c91086b9
patch 8.1.0519: cannot save and restore the tag stack
Bram Moolenaar <Bram@vim.org>
parents:
14301
diff
changeset
|
3 dict_T *dict_alloc_id(alloc_id_T id); |
13037
6e81a68d63a1
patch 8.0.1394: cannot intercept a yank command
Christian Brabandt <cb@256bit.org>
parents:
11418
diff
changeset
|
4 dict_T *dict_alloc_lock(int lock); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
5 int rettv_dict_alloc(typval_T *rettv); |
11418
162bcd0debd7
patch 8.0.0593: duplication of code for adding a list or dict return value
Christian Brabandt <cb@256bit.org>
parents:
9858
diff
changeset
|
6 void rettv_dict_set(typval_T *rettv, dict_T *d); |
13037
6e81a68d63a1
patch 8.0.1394: cannot intercept a yank command
Christian Brabandt <cb@256bit.org>
parents:
11418
diff
changeset
|
7 void dict_free_contents(dict_T *d); |
20347
0e1dfff4f294
patch 8.2.0729: Vim9: When reloading a script variables are not cleared
Bram Moolenaar <Bram@vim.org>
parents:
19102
diff
changeset
|
8 void hashtab_free_contents(hashtab_T *ht); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
9 void dict_unref(dict_T *d); |
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
10 int dict_free_nonref(int copyID); |
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
11 void dict_free_items(int copyID); |
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
12 dictitem_T *dictitem_alloc(char_u *key); |
31231
684e6dfa2fba
patch 9.0.0949: crash when unletting a variable while listing variables
Bram Moolenaar <Bram@vim.org>
parents:
29442
diff
changeset
|
13 void dictitem_remove(dict_T *dict, dictitem_T *item, char *command); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
14 void dictitem_free(dictitem_T *item); |
27517
f00a7a2bee21
patch 8.2.4286: Vim9: strict type checking after copy() and deepcopy()
Bram Moolenaar <Bram@vim.org>
parents:
26684
diff
changeset
|
15 dict_T *dict_copy(dict_T *orig, int deep, int top, int copyID); |
24764
3907cf9be745
patch 8.2.2920: still a way to shadow a builtin function
Bram Moolenaar <Bram@vim.org>
parents:
23088
diff
changeset
|
16 int dict_wrong_func_name(dict_T *d, typval_T *tv, char_u *name); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
17 int dict_add(dict_T *d, dictitem_T *item); |
14301
3c80092eb211
patch 8.1.0166: using dict_add_nr_str() is clumsy
Christian Brabandt <cb@256bit.org>
parents:
13037
diff
changeset
|
18 int dict_add_number(dict_T *d, char *key, varnumber_T nr); |
19102
ba9f50bfda83
patch 8.2.0111: VAR_SPECIAL is also used for booleans
Bram Moolenaar <Bram@vim.org>
parents:
19047
diff
changeset
|
19 int dict_add_bool(dict_T *d, char *key, varnumber_T nr); |
14301
3c80092eb211
patch 8.1.0166: using dict_add_nr_str() is clumsy
Christian Brabandt <cb@256bit.org>
parents:
13037
diff
changeset
|
20 int dict_add_string(dict_T *d, char *key, char_u *str); |
15267
762fccd84b7c
patch 8.1.0642: swapinfo() leaks memory
Bram Moolenaar <Bram@vim.org>
parents:
15146
diff
changeset
|
21 int dict_add_string_len(dict_T *d, char *key, char_u *str, int len); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
22 int dict_add_list(dict_T *d, char *key, list_T *list); |
19047
a3fce2763e83
patch 8.2.0084: complete item "user_data" can only be a string
Bram Moolenaar <Bram@vim.org>
parents:
17905
diff
changeset
|
23 int dict_add_tv(dict_T *d, char *key, typval_T *tv); |
17123
efc6f5e3b543
patch 8.1.1561: popup_setoptions() is not implemented yet
Bram Moolenaar <Bram@vim.org>
parents:
16902
diff
changeset
|
24 int dict_add_callback(dict_T *d, char *key, callback_T *cb); |
16447
54ffc82f38a8
patch 8.1.1228: not possible to process tags with a function
Bram Moolenaar <Bram@vim.org>
parents:
16268
diff
changeset
|
25 void dict_iterate_start(typval_T *var, dict_iterator_T *iter); |
54ffc82f38a8
patch 8.1.1228: not possible to process tags with a function
Bram Moolenaar <Bram@vim.org>
parents:
16268
diff
changeset
|
26 char_u *dict_iterate_next(dict_iterator_T *iter, typval_T **tv_result); |
9858
3e96d9ed2ca1
commit https://github.com/vim/vim/commit/b5ae48e9ffd3b8eb6ca4057de11f1bddcde8ce6f
Christian Brabandt <cb@256bit.org>
parents:
9556
diff
changeset
|
27 int dict_add_dict(dict_T *d, char *key, dict_T *dict); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
28 long dict_len(dict_T *d); |
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
29 dictitem_T *dict_find(dict_T *d, char_u *key, int len); |
28315
62cc3b60493b
patch 8.2.4683: verbose check with dict_find() to see if a key is present
Bram Moolenaar <Bram@vim.org>
parents:
27517
diff
changeset
|
30 int dict_has_key(dict_T *d, char *key); |
29442
827d9f2b7a71
patch 9.0.0063: too many type casts for dict_get functions
Bram Moolenaar <Bram@vim.org>
parents:
28315
diff
changeset
|
31 int dict_get_tv(dict_T *d, char *key, typval_T *rettv); |
827d9f2b7a71
patch 9.0.0063: too many type casts for dict_get functions
Bram Moolenaar <Bram@vim.org>
parents:
28315
diff
changeset
|
32 char_u *dict_get_string(dict_T *d, char *key, int save); |
827d9f2b7a71
patch 9.0.0063: too many type casts for dict_get functions
Bram Moolenaar <Bram@vim.org>
parents:
28315
diff
changeset
|
33 varnumber_T dict_get_number(dict_T *d, char *key); |
827d9f2b7a71
patch 9.0.0063: too many type casts for dict_get functions
Bram Moolenaar <Bram@vim.org>
parents:
28315
diff
changeset
|
34 varnumber_T dict_get_number_def(dict_T *d, char *key, int def); |
16902
23645f9a5ce2
patch 8.1.1452: line and col property of popup windows not properly checked
Bram Moolenaar <Bram@vim.org>
parents:
16447
diff
changeset
|
35 varnumber_T dict_get_number_check(dict_T *d, char_u *key); |
29442
827d9f2b7a71
patch 9.0.0063: too many type casts for dict_get functions
Bram Moolenaar <Bram@vim.org>
parents:
28315
diff
changeset
|
36 varnumber_T dict_get_bool(dict_T *d, char *key, int def); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
37 char_u *dict2string(typval_T *tv, int copyID, int restore_copyID); |
23088
285cde4b8d0e
patch 8.2.2090: Vim9: dict does not accept a key in quotes
Bram Moolenaar <Bram@vim.org>
parents:
23072
diff
changeset
|
38 char_u *get_literal_key(char_u **arg); |
21034
2f8b0812819f
patch 8.2.1068: Vim9: no line break allowed inside a dict
Bram Moolenaar <Bram@vim.org>
parents:
20347
diff
changeset
|
39 int eval_dict(char_u **arg, typval_T *rettv, evalarg_T *evalarg, int literal); |
25326
cfbf40f749b0
patch 8.2.3200: Vim9: hard to guess where a type error is given
Bram Moolenaar <Bram@vim.org>
parents:
24764
diff
changeset
|
40 void dict_extend(dict_T *d1, dict_T *d2, char_u *action, char *func_name); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
41 dictitem_T *dict_lookup(hashitem_T *hi); |
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
42 int dict_equal(dict_T *d1, dict_T *d2, int ic, int recursive); |
26684
2126feddeda6
patch 8.2.3871: list.c contains code for dict and blob
Bram Moolenaar <Bram@vim.org>
parents:
25567
diff
changeset
|
43 long dict_count(dict_T *d, typval_T *needle, int ic); |
2126feddeda6
patch 8.2.3871: list.c contains code for dict and blob
Bram Moolenaar <Bram@vim.org>
parents:
25567
diff
changeset
|
44 void dict_extend_func(typval_T *argvars, type_T *type, char *func_name, char_u *arg_errmsg, int is_new, typval_T *rettv); |
2126feddeda6
patch 8.2.3871: list.c contains code for dict and blob
Bram Moolenaar <Bram@vim.org>
parents:
25567
diff
changeset
|
45 void dict_filter_map(dict_T *d, filtermap_T filtermap, type_T *argtype, char *func_name, char_u *arg_errmsg, typval_T *expr, typval_T *rettv); |
2126feddeda6
patch 8.2.3871: list.c contains code for dict and blob
Bram Moolenaar <Bram@vim.org>
parents:
25567
diff
changeset
|
46 void dict_remove(typval_T *argvars, typval_T *rettv, char_u *arg_errmsg); |
17530
ef23ec1eee54
patch 8.1.1763: evalfunc.c is still too big
Bram Moolenaar <Bram@vim.org>
parents:
17368
diff
changeset
|
47 void f_items(typval_T *argvars, typval_T *rettv); |
ef23ec1eee54
patch 8.1.1763: evalfunc.c is still too big
Bram Moolenaar <Bram@vim.org>
parents:
17368
diff
changeset
|
48 void f_keys(typval_T *argvars, typval_T *rettv); |
ef23ec1eee54
patch 8.1.1763: evalfunc.c is still too big
Bram Moolenaar <Bram@vim.org>
parents:
17368
diff
changeset
|
49 void f_values(typval_T *argvars, typval_T *rettv); |
13037
6e81a68d63a1
patch 8.0.1394: cannot intercept a yank command
Christian Brabandt <cb@256bit.org>
parents:
11418
diff
changeset
|
50 void dict_set_items_ro(dict_T *di); |
17530
ef23ec1eee54
patch 8.1.1763: evalfunc.c is still too big
Bram Moolenaar <Bram@vim.org>
parents:
17368
diff
changeset
|
51 void f_has_key(typval_T *argvars, typval_T *rettv); |
9556
afaff1d283d3
commit https://github.com/vim/vim/commit/cd52459c387785796713826c63174cdeed295dd4
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
52 /* vim: set ft=c : */ |