From 7b9ddea80b12fa39f38e6742166399d23c818adc Mon Sep 17 00:00:00 2001 From: Ned Deily Date: Wed, 5 Feb 2014 16:53:10 -0800 Subject: [PATCH] Issue #20374: Avoid compiler warnings when compiling readline with libedit. --- Modules/readline.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Modules/readline.c b/Modules/readline.c index 4ee17a91cd9..ae3e14365f7 100644 --- a/Modules/readline.c +++ b/Modules/readline.c @@ -773,15 +773,24 @@ on_hook(PyObject *func) return result; } + static int +#if defined(_RL_FUNCTION_TYPEDEF) on_startup_hook(void) +#else +on_startup_hook() +#endif { return on_hook(startup_hook); } #ifdef HAVE_RL_PRE_INPUT_HOOK static int +#if defined(_RL_FUNCTION_TYPEDEF) on_pre_input_hook(void) +#else +on_pre_input_hook() +#endif { return on_hook(pre_input_hook); }