From 3b9d55bd9c9180cc94de96bf60f7bfa5d5f8f2cc Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Wed, 20 Oct 2010 12:58:49 +1030 Subject: [PATCH] typesafe_cb: 64 bit fixes. In particular, gcc warns about cast from int to pointer. --- ccan/typesafe_cb/test/compile_fail-cast_if_type-promotable.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ccan/typesafe_cb/test/compile_fail-cast_if_type-promotable.c b/ccan/typesafe_cb/test/compile_fail-cast_if_type-promotable.c index a0362485..016d0e2a 100644 --- a/ccan/typesafe_cb/test/compile_fail-cast_if_type-promotable.c +++ b/ccan/typesafe_cb/test/compile_fail-cast_if_type-promotable.c @@ -6,7 +6,7 @@ static void _set_some_value(void *val) } #define set_some_value(expr) \ - _set_some_value(cast_if_type(void *, (expr), (expr), int)) + _set_some_value(cast_if_type(void *, (expr), (expr), long)) int main(int argc, char *argv[]) { @@ -16,7 +16,7 @@ int main(int argc, char *argv[]) #error "Unfortunately we don't fail if cast_if_type is a noop." #endif #else - int x = 0; + long x = 0; #endif set_some_value(x); return 0; -- 2.39.2