Mercurial > vim
changeset 22151:01cab6232a9a v8.2.1625
patch 8.2.1625: compiler warning for use of fptr_T
Commit: https://github.com/vim/vim/commit/30d6413782c8206899cee109f521895a03c76441
Author: Bram Moolenaar <Bram@vim.org>
Date: Sun Sep 6 17:09:12 2020 +0200
patch 8.2.1625: compiler warning for use of fptr_T
Problem: Compiler warning for use of fptr_T.
Solution: Make the type less strict.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sun, 06 Sep 2020 17:15:03 +0200 |
parents | 9a7b86f483f3 |
children | 4150aaf0f253 |
files | src/regexp.c src/version.c |
diffstat | 2 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/regexp.c +++ b/src/regexp.c @@ -1691,9 +1691,9 @@ cstrchr(char_u *s, int c) * We should define ftpr as a pointer to a function returning a pointer to * a function returning a pointer to a function ... * This is impossible, so we declare a pointer to a function returning a - * pointer to a function returning void. This should work for all compilers. + * void pointer. This should work for all compilers. */ -typedef void (*(*fptr_T)(int *, int))(); +typedef void (*(*fptr_T)(int *, int)); static int vim_regsub_both(char_u *source, typval_T *expr, char_u *dest, int copy, int magic, int backslash);