[PATCH] evaluate: mark evaluate_generic_selection() as static

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Commit c100a7ab (add support for _Generic, 2020-05-28) added the
function evaluate_generic_selection() as an external symbol, without
providing an external declaration in a header file. This causes
sparse to issue a warning as part of the 'selfcheck' target.

Since this function does not (currently) need to be an external symbol,
mark it as static.

Signed-off-by: Ramsay Jones <ramsay@xxxxxxxxxxxxxxxxxxxx>
---
 evaluate.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/evaluate.c b/evaluate.c
index 5f2b7d6f..8d2e6869 100644
--- a/evaluate.c
+++ b/evaluate.c
@@ -3280,7 +3280,7 @@ static int type_selection(struct symbol *ctrl, struct symbol *type)
 	return !type_difference(&c, &t, 0, 0);
 }
 
-struct symbol *evaluate_generic_selection(struct expression *expr)
+static struct symbol *evaluate_generic_selection(struct expression *expr)
 {
 	struct type_expression *map;
 	struct expression *res;
-- 
2.26.2



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux