From ecda2093f19088fa94c3a4ac85359c6d0f1c64af Mon Sep 17 00:00:00 2001 From: Luc Van Oostenryck Date: Wed, 22 Mar 2017 16:52:02 +0100 Subject: [PATCH] fix is_scalar_type() This helper was introduced to add some warning in conditionals which must accept arrays and functions as those degenerate as pointers in this context. There was some sign of a bug somewhere but it wasn't seen and as consequence arrays and function type were added to scalar type (yeah, brown paper bag). Now that the bug is solved, fix this by removing array and function type from is_scalar_type(). Signed-off-by: Luc Van Oostenryck --- symbol.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/symbol.h b/symbol.h index 512a2f69..32744961 100644 --- a/symbol.h +++ b/symbol.h @@ -395,8 +395,6 @@ static inline int is_scalar_type(struct symbol *type) case SYM_ENUM: case SYM_BITFIELD: case SYM_PTR: - case SYM_ARRAY: // OK, will be a PTR after conversion - case SYM_FN: case SYM_RESTRICT: // OK, always integer types return 1; default: -- 2.11.4.GIT