diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2007-07-02 00:43:37 -0400 |
---|---|---|
committer | Josh Triplett <josh@freedesktop.org> | 2007-07-14 12:16:52 -0700 |
commit | f91d6af29636632f70613cb42aabdc9d417e355d (patch) | |
tree | b1007a44f5a378b709a5e85dfede1e5d54a2dbd6 /evaluate.c | |
parent | [PATCH] clean up evaluate_sign() (diff) | |
download | sparse-f91d6af29636632f70613cb42aabdc9d417e355d.tar.gz sparse-f91d6af29636632f70613cb42aabdc9d417e355d.tar.bz2 sparse-f91d6af29636632f70613cb42aabdc9d417e355d.zip |
[PATCH] integer_promotions() can't get SYM_NODE or SYM_ENUM
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'evaluate.c')
-rw-r--r-- | evaluate.c | 9 |
1 files changed, 2 insertions, 7 deletions
@@ -98,17 +98,12 @@ static struct symbol *evaluate_string(struct expression *expr) return sym; } +/* type has come from classify_type and is an integer type */ static inline struct symbol *integer_promotion(struct symbol *type) { struct symbol *orig_type = type; unsigned long mod = type->ctype.modifiers; - int width; - - if (type->type == SYM_NODE) - type = type->ctype.base_type; - if (type->type == SYM_ENUM) - type = type->ctype.base_type; - width = type->bit_size; + int width = type->bit_size; /* * Bitfields always promote to the base type, |