Go to the source code of this file.
Defines | |
#define | set_state(s) do { tmp = p->state; p->state = s; p->prev_state = tmp; } while(0) |
#define | fetch_next_char() |
Enumerations | |
enum | { S_START, S_IN_DOUBLE_QUOTE, S_IN_SINGLE_QUOTE, S_HTML, S_WAIT_PERC, S_START_CODE, S_CODE, S_WAIT_GT, S_EAT_NEWLINE } |
enum | { LF = 0xA, CR = 0xD } |
Functions | |
int | parser_run (parser_t *p) |
void | parser_set_cb_code (parser_t *p, parser_cb_code_t cb) |
void | parser_set_cb_html (parser_t *p, parser_cb_html_t cb) |
void | parser_set_cb_arg (parser_t *p, void *opaque) |
void | parser_set_io (parser_t *p, io_t *in, io_t *out) |
int | parser_free (parser_t *t) |
int | parser_reset (parser_t *p) |
int | parser_create (parser_t **pt) |
|
Value: do { prev = c; \ dbg_err_if((rc = io_getc(p->in, &c)) < 0); \ if(rc == 0) break; \ if( (c == CR || c == LF) && prev != (c == CR ? LF : CR)) \ p->line++; \ } while(0) Referenced by parser_run(). |
|
Referenced by parser_run(). |
|
|
|
|
|
Definition at line 245 of file parser.c. References parser_free(), parser_reset(), and parser_t. Referenced by translate_script_to_c(). |
|
Definition at line 228 of file parser.c. References parser_t. Referenced by parser_create(), and translate_script_to_c(). |
|
Definition at line 234 of file parser.c. References parser_s::cmd_code, parser_s::line, parser_t, parser_s::prev_state, and parser_s::state. Referenced by parser_create(). |
|
Definition at line 73 of file parser.c. References parser_s::cmd_code, parser_s::code_line, CR, fetch_next_char, parser_s::line, parser_t, parser_s::prev_state, S_CODE, S_EAT_NEWLINE, S_HTML, S_IN_DOUBLE_QUOTE, S_IN_SINGLE_QUOTE, S_START, S_START_CODE, S_WAIT_GT, S_WAIT_PERC, set_state, and parser_s::state. Referenced by translate_script_to_c(). |
|
Definition at line 215 of file parser.c. References parser_s::cb_arg, and parser_t. Referenced by translate_script_to_c(). |
|
Definition at line 203 of file parser.c. References parser_s::cb_code, and parser_t. Referenced by translate_script_to_c(). |
|
Definition at line 209 of file parser.c. References parser_s::cb_html, and parser_t. Referenced by translate_script_to_c(). |
|
Definition at line 221 of file parser.c. References parser_s::in, io_t, parser_s::out, and parser_t. Referenced by translate_script_to_c(). |