evaluate: mark evaluate_generic_selection() as static
PATCH 1/1 evaluate: mark evaluate_generic_selection() as static
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.
--- evaluate.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
evaluate.c +1 -1
@@ -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;
Signature · 1 line
2.26.2
Quoted 8 lines · Ramsay Jones
Commit
c100a7ab(add support for_Generic, 2020-05-28) added the functionevaluate_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.
Hmm, yes. I should taste my own dogfood and use 'make selfcheck' ... Thanks.
-- Luc