This will make later checks easier & clearer. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx> --- symbol.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/symbol.h b/symbol.h index 287df0a3a0ee..c9e6c7fe4439 100644 --- a/symbol.h +++ b/symbol.h @@ -507,6 +507,13 @@ static inline int is_extern_inline(struct symbol *sym) is_function(sym->ctype.base_type); } +static inline int has_flexible_array(struct symbol *type) +{ + if (type->type == SYM_NODE) + type = type->ctype.base_type; + return type->has_flex_array; +} + static inline int get_sym_type(struct symbol *type) { if (type->type == SYM_NODE) -- 2.28.0