kconfig: qconf: fix incomplete type 'struct gstr' warning
authorMasahiro Yamada <masahiroy@kernel.org>
Tue, 8 Sep 2020 22:16:38 +0000 (07:16 +0900)
committerChristian Lamparter <chunkeey@gmail.com>
Fri, 5 Feb 2021 11:04:09 +0000 (12:04 +0100)
commitb89034ef7b6559dbe8fbde41d0a4a2c68b74861d
tree264afd03fa197a191f6faa27c3678d0513530c0f
parent2c7842933aa7936171c78fdb62d6d8393e28ee87
kconfig: qconf: fix incomplete type 'struct gstr' warning

"make HOSTCXX=clang++ xconfig" reports the following:

  HOSTCXX scripts/kconfig/qconf.o
In file included from scripts/kconfig/qconf.cc:23:
In file included from scripts/kconfig/lkc.h:15:
scripts/kconfig/lkc_proto.h:26:13: warning: 'get_relations_str' has C-linkage specified, but returns incomplete type 'struct gstr' which could be incompatible with C [-Wreturn-type-c-linkage]
struct gstr get_relations_str(struct symbol **sym_arr, struct list_head *head);
            ^

Currently, get_relations_str() is declared before the struct gstr
definition.

Move all declarations of menu.c functions below.

BTW, some are declared in lkc.h and some in lkc_proto.h, but the
difference is unclear. I guess some refactoring is needed.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Acked-by: Boris Kolpackov <boris@codesynthesis.com>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
config/lkc.h
config/lkc_proto.h