From 47f9f88d9f9dd21dc0eafdd23b5c9c5ea7830183 Mon Sep 17 00:00:00 2001 From: Vincenzo Calabretta Date: Sat, 27 Apr 2024 21:43:21 +0200 Subject: [PATCH] test/metal-test.h: Fix warning -Wstrict-prototypes Small change to solve the warning: function declaration isn't a prototype when compiling tests with -Wstrict-prototypes gcc option enabled. Signed-off-by: Vincenzo Calabretta --- test/metal-test.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/metal-test.h b/test/metal-test.h index e1a18ac9..495b561b 100644 --- a/test/metal-test.h +++ b/test/metal-test.h @@ -33,7 +33,8 @@ extern void metal_add_test_case(struct metal_test_case *test_case); #define METAL_ADD_TEST(func) \ -__attribute__ ((constructor)) static void metal_test_##func() { \ +__attribute__ ((constructor)) static void metal_test_##func(void) \ +{ \ static struct metal_test_case metal_test_##func = { \ .name = #func, \ .test = func, \