Mercurial > vim
diff src/insexpand.c @ 31996:ca6bc7c04163 v9.0.1330
patch 9.0.1330: handling new value of an option has a long "else if" chain
Commit: https://github.com/vim/vim/commit/af93691b53f38784efce0b93fe7644c44a7e382e
Author: Yegappan Lakshmanan <yegappan@yahoo.com>
Date: Mon Feb 20 12:16:39 2023 +0000
patch 9.0.1330: handling new value of an option has a long "else if" chain
Problem: Handling new value of an option has a long "else if" chain.
Solution: Use a function pointer. (Yegappan Lakshmanan, closes https://github.com/vim/vim/issues/12015)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 20 Feb 2023 13:30:05 +0100 |
parents | 8b15e4161605 |
children | 4545f58c8490 |
line wrap: on
line diff
--- a/src/insexpand.c +++ b/src/insexpand.c @@ -2546,7 +2546,7 @@ copy_global_to_buflocal_cb(callback_T *g * lambda expression. */ char * -set_completefunc_option(void) +did_set_completefunc(optset_T *args UNUSED) { if (option_set_callback_func(curbuf->b_p_cfu, &cfu_cb) == FAIL) return e_invalid_argument; @@ -2575,7 +2575,7 @@ set_buflocal_cfu_callback(buf_T *buf UNU * lambda expression. */ char * -set_omnifunc_option(void) +did_set_omnifunc(optset_T *args UNUSED) { if (option_set_callback_func(curbuf->b_p_ofu, &ofu_cb) == FAIL) return e_invalid_argument; @@ -2603,7 +2603,7 @@ set_buflocal_ofu_callback(buf_T *buf UNU * lambda expression. */ char * -set_thesaurusfunc_option(void) +did_set_thesaurusfunc(optset_T *args UNUSED) { int retval;