From: Alan Cox Date: Fri, 13 Oct 2017 19:30:22 +0000 (+0100) Subject: test: fix compilation with newer SDCC X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=41f4a7015fd197a46f52d8454884a8bb023db32f;p=FUZIX.git test: fix compilation with newer SDCC void * and function types don't mix in strict interpretations of C (think about split I/D for one) Patch from Philipp Klaus Krause. --- diff --git a/Applications/MWC/cmd/test.c b/Applications/MWC/cmd/test.c index a7e7b7ec..beafc37b 100644 --- a/Applications/MWC/cmd/test.c +++ b/Applications/MWC/cmd/test.c @@ -198,9 +198,9 @@ STRING_UNOP(strfile_executable) struct op { const char *op_name; - void *op_func; + void (*op_func)(void); }; -#define OP(name,func) { name, (void *)func } +#define OP(name,func) { name, (void (*)(void *))func } const struct op string_binop[] = { OP("=", cmp_eq), OP("!=", cmp_neq), OP("<", cmp_lt),