X-Git-Url: https://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=ccan%2Ftypesafe_cb%2Ftest%2Fcompile_fail-typesafe_cb.c;fp=ccan%2Ftypesafe_cb%2Ftest%2Fcompile_fail-typesafe_cb.c;h=81e36d7b87b901fb4922e5e3174ef466b242ec9a;hp=bcc6ed63ea51c5a0f912514fb14c8c970eda488d;hb=b0fa019adb998c20a8740f5696b61ae87d2a77a6;hpb=076877c266706ba432987195422a1e8653bd0c3b diff --git a/ccan/typesafe_cb/test/compile_fail-typesafe_cb.c b/ccan/typesafe_cb/test/compile_fail-typesafe_cb.c index bcc6ed63..81e36d7b 100644 --- a/ccan/typesafe_cb/test/compile_fail-typesafe_cb.c +++ b/ccan/typesafe_cb/test/compile_fail-typesafe_cb.c @@ -6,7 +6,7 @@ static void _register_callback(void (*cb)(void *arg), void *arg) } #define register_callback(cb, arg) \ - _register_callback(typesafe_cb(void, (cb), (arg)), (arg)) + _register_callback(typesafe_cb(void, void *, (cb), (arg)), (arg)) static void my_callback(char *p) { @@ -18,7 +18,7 @@ int main(int argc, char *argv[]) #ifdef FAIL int *p; #if !HAVE_TYPEOF||!HAVE_BUILTIN_CHOOSE_EXPR||!HAVE_BUILTIN_TYPES_COMPATIBLE_P -#error "Unfortunately we don't fail if cast_if_type is a noop." +#error "Unfortunately we don't fail if typesafe_cb_cast is a noop." #endif #else char *p;