1 | #ifndef CONSTS_H
|
2 | #define CONSTS_H
|
3 |
|
4 | #include "mycpp/runtime.h"
|
5 |
|
6 | #include "_gen/frontend/id_kind.asdl.h"
|
7 | #include "_gen/frontend/option.asdl.h"
|
8 | #include "_gen/core/runtime.asdl.h"
|
9 | #include "_gen/frontend/types.asdl.h"
|
10 |
|
11 | namespace consts {
|
12 |
|
13 | extern List<int>* STRICT_ALL;
|
14 | extern List<int>* YSH_UPGRADE;
|
15 | extern List<int>* YSH_ALL;
|
16 | extern List<int>* DEFAULT_TRUE;
|
17 | extern List<int>* PARSE_OPTION_NUMS;
|
18 | extern List<int>* SHOPT_OPTION_NUMS;
|
19 | extern List<int>* SET_OPTION_NUMS;
|
20 | extern List<int>* VISIBLE_SHOPT_NUMS;
|
21 | extern List<BigStr*>* BUILTIN_NAMES;
|
22 | extern List<BigStr*>* OSH_KEYWORD_NAMES;
|
23 | extern List<BigStr*>* SET_OPTION_NAMES;
|
24 | extern List<BigStr*>* SHOPT_OPTION_NAMES;
|
25 |
|
26 | extern int NO_INDEX;
|
27 |
|
28 | extern BigStr* gVersion;
|
29 |
|
30 | int RedirDefaultFd(id_kind_asdl::Id_t id);
|
31 | types_asdl::redir_arg_type_t RedirArgType(id_kind_asdl::Id_t id);
|
32 | types_asdl::bool_arg_type_t BoolArgType(id_kind_asdl::Id_t id);
|
33 | id_kind_asdl::Kind GetKind(id_kind_asdl::Id_t id);
|
34 |
|
35 | types_asdl::opt_group_t OptionGroupNum(BigStr* s);
|
36 | option_asdl::option_t OptionNum(BigStr* s);
|
37 | option_asdl::builtin_t LookupNormalBuiltin(BigStr* s);
|
38 | option_asdl::builtin_t LookupAssignBuiltin(BigStr* s);
|
39 | option_asdl::builtin_t LookupSpecialBuiltin(BigStr* s);
|
40 | bool IsControlFlow(BigStr* s);
|
41 | BigStr* ControlFlowName(int i);
|
42 | bool IsKeyword(BigStr* s);
|
43 | BigStr* LookupCharC(BigStr* c);
|
44 | BigStr* LookupCharPrompt(BigStr* c);
|
45 |
|
46 | BigStr* OptionName(option_asdl::option_t opt_num);
|
47 |
|
48 | Tuple2<runtime_asdl::state_t, runtime_asdl::emit_t> IfsEdge(runtime_asdl::state_t state, runtime_asdl::char_kind_t ch);
|
49 |
|
50 | } // namespace consts
|
51 |
|
52 | #endif // CONSTS_H
|
53 |
|