aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAl Viro <viro@ftp.linux.org.uk>2009-03-09 07:13:08 +0000
committerChristopher Li <sparse@chrisli.org>2009-07-18 05:30:09 +0000
commit1aae3184cb1dbf95e1e07b4ac85cd3c70784fd32 (patch)
tree97633774fffd1f6f7949de43ae8f9f67daa11406 /symbol.h
parentPass decl_state down to ->attribute() (diff)
downloadsparse-1aae3184cb1dbf95e1e07b4ac85cd3c70784fd32.tar.gz
sparse-1aae3184cb1dbf95e1e07b4ac85cd3c70784fd32.tar.bz2
sparse-1aae3184cb1dbf95e1e07b4ac85cd3c70784fd32.zip
Restore __attribute__((mode)) handling
... at least to the extent we used to do it. It still does _not_ cover the perversions gcc can do with that, but at least it deals with regressions. Full solution will have to wait for full-blown imitation of what gcc people call __attribute__ semantics, the bastards... Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Christopher Li <sparse@chrisli.org>
Diffstat (limited to 'symbol.h')
-rw-r--r--symbol.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/symbol.h b/symbol.h
index b74ab0c..f9944bf 100644
--- a/symbol.h
+++ b/symbol.h
@@ -91,8 +91,9 @@ struct ctype {
struct decl_state {
struct ctype ctype;
- int prefer_abstract;
struct ident **ident;
+ int prefer_abstract;
+ struct symbol_op *mode;
};
struct symbol_op {
@@ -106,6 +107,7 @@ struct symbol_op {
struct token *(*statement)(struct token *token, struct statement *stmt);
struct token *(*toplevel)(struct token *token, struct symbol_list **list);
struct token *(*attribute)(struct token *token, struct symbol *attr, struct decl_state *ctx);
+ struct symbol *(*to_mode)(struct symbol *);
int test, set, class;
};