Mercurial > vim
comparison src/evalfunc.c @ 31772:152bb9e6b4b4 v9.0.1218
patch 9.0.1218: completion includes functions that don't work
Commit: https://github.com/vim/vim/commit/90c2353365c5da40dec01b09e1f482983cf7f55d
Author: Kota Kato <github@kat0h.com>
Date: Wed Jan 18 15:27:38 2023 +0000
patch 9.0.1218: completion includes functions that don't work
Problem: Completion includes functions that don't work.
Solution: Skip functions that are not implemented. (Kota Kato,
closes #11845)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 18 Jan 2023 16:30:06 +0100 |
parents | f348559ce426 |
children | ddbc560ecc41 |
comparison
equal
deleted
inserted
replaced
31771:03c8e327f5ee | 31772:152bb9e6b4b4 |
---|---|
2870 return name; | 2870 return name; |
2871 } | 2871 } |
2872 } | 2872 } |
2873 if (++intidx < (int)ARRAY_LENGTH(global_functions)) | 2873 if (++intidx < (int)ARRAY_LENGTH(global_functions)) |
2874 { | 2874 { |
2875 // Skip if the function doesn't have an implementation (feature not | |
2876 // implemented). | |
2877 if (global_functions[intidx].f_func == NULL) | |
2878 return (char_u *)""; | |
2875 STRCPY(IObuff, global_functions[intidx].f_name); | 2879 STRCPY(IObuff, global_functions[intidx].f_name); |
2876 STRCAT(IObuff, "("); | 2880 STRCAT(IObuff, "("); |
2877 if (global_functions[intidx].f_max_argc == 0) | 2881 if (global_functions[intidx].f_max_argc == 0) |
2878 STRCAT(IObuff, ")"); | 2882 STRCAT(IObuff, ")"); |
2879 return IObuff; | 2883 return IObuff; |