Commit | Line | Data |
---|---|---|
34e49164 C |
1 | |
2 | val _handle_typedef : bool ref | |
3 | ||
4 | val enable_typedef : unit -> unit | |
5 | val disable_typedef : unit -> unit | |
6 | val is_enabled_typedef : unit -> bool | |
7 | ||
8 | ||
9 | ||
10 | (* private *) | |
11 | type identkind = TypeDefI | IdentI | |
12 | val _typedef : (string, identkind) Common.scoped_h_env ref | |
13 | ||
14 | val add_ident : string -> unit | |
15 | val add_typedef : string -> unit | |
978fd7e5 | 16 | |
34e49164 C |
17 | val add_typedef_root : string -> unit |
18 | ||
19 | val new_scope : unit -> unit | |
20 | val del_scope : unit -> unit | |
21 | ||
22 | val is_typedef : string -> bool | |
23 | ||
ca417fcf C |
24 | val lexer_reset_typedef : |
25 | (string, identkind) Common.scoped_h_env option (* known typedefs *) -> unit | |
34e49164 C |
26 | |
27 | val _old_state : (string, identkind) Common.scoped_h_env ref | |
28 | val save_typedef_state : unit -> unit | |
29 | val restore_typedef_state : unit -> unit | |
30 | ||
31 | ||
ae4735db | 32 | type context = |
485bce71 C |
33 | | InTopLevel |
34 | | InFunction | |
35 | | InStruct | |
36 | | InParameter | |
37 | | InInitializer | |
38 | | InEnum | |
39 | ||
ae4735db | 40 | type lexer_hint = { |
485bce71 C |
41 | mutable context_stack: context Common.stack; |
42 | } | |
34e49164 C |
43 | |
44 | val _lexer_hint : lexer_hint ref | |
485bce71 C |
45 | val current_context: unit -> context |
46 | val push_context: context -> unit | |
47 | val pop_context: unit -> unit | |
34e49164 C |
48 | |
49 | val default_hint : unit -> lexer_hint | |
978fd7e5 C |
50 | |
51 | val is_top_or_struct : context -> bool | |
52 |