extra: revert the mod_expr changes for modify expression hooks
[smatch.git] / dissect.h
bloba77a9328f416e331b7b4e727d25e7221a990d42e
1 #ifndef DISSECT_H
2 #define DISSECT_H
4 #include <stdio.h>
5 #include "parse.h"
6 #include "expression.h"
7 #include "scope.h"
9 #define U_SHIFT 8
11 #define U_R_AOF 0x01
12 #define U_W_AOF 0x02
14 #define U_R_VAL 0x04
15 #define U_W_VAL 0x08
17 #define U_R_PTR (U_R_VAL << U_SHIFT)
18 #define U_W_PTR (U_W_VAL << U_SHIFT)
20 struct reporter
22 void (*r_symdef)(struct symbol *);
23 void (*r_memdef)(struct symbol *, struct symbol *);
25 void (*r_symbol)(unsigned, struct position *, struct symbol *);
26 void (*r_member)(unsigned, struct position *, struct symbol *, struct symbol *);
29 extern struct symbol *dissect_ctx;
31 static inline bool sym_is_local(struct symbol *sym)
33 return !toplevel(sym->scope);
36 extern void dissect(struct reporter *, struct string_list *);
38 #endif