diff mbox

[7/7] fix is_scalar_type()

Message ID 20170322173257.63019-8-luc.vanoostenryck@gmail.com (mailing list archive)
State Mainlined, archived
Headers show

Commit Message

Luc Van Oostenryck March 22, 2017, 5:32 p.m. UTC
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 <luc.vanoostenryck@gmail.com>
---
 symbol.h | 2 --
 1 file changed, 2 deletions(-)
diff mbox

Patch

diff --git a/symbol.h b/symbol.h
index 512a2f69f..327449611 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: