4 DECLARE_PTR_LIST(history_list
, struct state_history
);
10 struct smatch_state
*state
;
11 struct history_list
*line_history
;
12 struct history_list
*path_history
;
15 DECLARE_ALLOCATOR(sm_state
);
16 DECLARE_PTR_LIST(state_list
, struct sm_state
);
17 DECLARE_PTR_LIST(state_list_stack
, struct state_list
);
20 struct state_list
*slist
;
22 DECLARE_ALLOCATOR(named_slist
);
23 DECLARE_PTR_LIST(slist_stack
, struct named_slist
);
25 void add_history(struct sm_state
*state
);
26 struct sm_state
*alloc_state(const char *name
, int owner
,
28 struct smatch_state
*state
);
30 struct sm_state
*clone_state(struct sm_state
*s
);
31 struct state_list
*clone_slist(struct state_list
*from_slist
);
33 struct smatch_state
*merge_states(const char *name
, int owner
,
35 struct smatch_state
*state1
,
36 struct smatch_state
*state2
);
38 struct smatch_state
*get_state_slist(struct state_list
*slist
, const char *name
, int owner
,
41 void set_state_slist(struct state_list
**slist
, const char *name
, int owner
,
42 struct symbol
*sym
, struct smatch_state
*state
);
44 void merge_state_slist(struct state_list
**slist
, const char *name
, int owner
,
45 struct symbol
*sym
, struct smatch_state
*state
);
47 void delete_state_slist(struct state_list
**slist
, const char *name
, int owner
,
50 struct smatch_state
*get_state_slist(struct state_list
*slist
, const char *name
, int owner
,
53 void push_slist(struct state_list_stack
**list_stack
, struct state_list
*slist
);
55 struct state_list
*pop_slist(struct state_list_stack
**list_stack
);
57 void del_slist(struct state_list
**slist
);
59 void del_slist_stack(struct state_list_stack
**slist_stack
);
61 void set_state_stack(struct state_list_stack
**stack
, const char *name
,
62 int owner
, struct symbol
*sym
, struct smatch_state
*state
);
64 struct smatch_state
*get_state_stack(struct state_list_stack
*stack
, const char *name
,
65 int owner
, struct symbol
*sym
);
67 void merge_slist(struct state_list
**to
, struct state_list
*slist
);
68 void filter(struct state_list
**slist
, struct state_list
*filter
);
69 void and_slist_stack(struct state_list_stack
**slist_stack
);
71 void or_slist_stack(struct state_list_stack
**slist_stack
);
73 struct state_list
**get_slist_from_slist_stack(struct slist_stack
*stack
,
76 void overwrite_slist(struct state_list
*from
, struct state_list
**to
);