32 |
typedef struct rc_bool RC_BOOL; |
typedef struct rc_bool RC_BOOL; |
33 |
typedef struct rc_expr RC_EXPR; |
typedef struct rc_expr RC_EXPR; |
34 |
typedef struct rc_inst RC_INST; |
typedef struct rc_inst RC_INST; |
35 |
|
typedef struct rc_loc RC_LOC; |
36 |
|
|
37 |
|
struct rc_loc { |
38 |
|
char *file; |
39 |
|
size_t line; |
40 |
|
}; |
41 |
|
|
42 |
struct rc_section { /* RC Section */ |
struct rc_section { /* RC Section */ |
43 |
|
RC_LOC loc; /* Location in the config file */ |
44 |
RC_SECTION *next; /* Link to the next section */ |
RC_SECTION *next; /* Link to the next section */ |
45 |
char *name; /* Section name */ |
char *name; /* Section name */ |
46 |
RC_STMT *stmt; /* List of parsed statements */ |
RC_STMT *stmt; /* List of parsed statements */ |
82 |
}; |
}; |
83 |
|
|
84 |
struct rc_node { /* Executable node */ |
struct rc_node { /* Executable node */ |
85 |
|
RC_LOC loc; /* Location in the config file */ |
86 |
enum rc_node_type type; /* Node type */ |
enum rc_node_type type; /* Node type */ |
87 |
union { |
union { |
88 |
RC_EXPR expr; |
RC_EXPR expr; |
118 |
}; |
}; |
119 |
|
|
120 |
struct rc_stmt { /* General statement representation */ |
struct rc_stmt { /* General statement representation */ |
121 |
|
RC_LOC loc; /* Location in the config file */ |
122 |
RC_STMT *next; /* Link to the next statement */ |
RC_STMT *next; /* Link to the next statement */ |
123 |
enum rc_stmt_type type; /* Statement type */ |
enum rc_stmt_type type; /* Statement type */ |
124 |
union { /* Actual data */ |
union { /* Actual data */ |
191 |
struct rc_secdef *anubis_find_section(char *); |
struct rc_secdef *anubis_find_section(char *); |
192 |
|
|
193 |
void parse_error(const char *fmt, ...); |
void parse_error(const char *fmt, ...); |
194 |
|
|
195 |
|
void trace(RC_LOC *loc, const char *fmt, ...); |