From f79f5e37f0e4b06d5dc303cc219929d7359dd7df Mon Sep 17 00:00:00 2001 From: Biswapriyo Nath Date: Thu, 18 May 2023 03:53:32 +0530 Subject: Fix function declaration warnings with clang (#226) This fixes the following compiler warnings with clang tools/genperf/perfect.c:65:6: warning: a function definition without a prototype is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype] frontends/yasm/yasm.c:1379:23: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes] modules/objfmts/elf/elf.c:225:18: warning: a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes] --- tools/genperf/perfect.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'tools/genperf/perfect.c') diff --git a/tools/genperf/perfect.c b/tools/genperf/perfect.c index fa5a4897..318cb5e6 100644 --- a/tools/genperf/perfect.c +++ b/tools/genperf/perfect.c @@ -62,8 +62,7 @@ Find the mapping that will produce a perfect hash */ /* return the ceiling of the log (base 2) of val */ -ub4 phash_log2(val) -ub4 val; +ub4 phash_log2(ub4 val) { ub4 i; for (i=0; ((ub4)1<