#include "gwion_util.h"
#include "gwion_ast.h"
#include "bison_compat.h"
Go to the source code of this file.
◆ free_pp()
ANN void free_pp |
( |
MemPool | p, |
|
|
PP * | pp, |
|
|
void * | data ) |
Definition at line 38 of file pp.c.
38 {
40 vector_release(&pp->
state);
43 mp_free(p, Hash, pp->
macros);
44 vector_release(&pp->
data);
46}
static void pp_post(PP *pp, void *data)
struct Vector_ global_undef
◆ new_pp()
ANEW PP * new_pp |
( |
MemPool | p, |
|
|
const uint | size, |
|
|
const char * | name ) |
Definition at line 11 of file pp.c.
11 {
12 PP *pp = (
PP *)mp_calloc(p,
PP);
13 vector_init(&pp->
data);
14 pp->
macros = (Hash)mp_calloc(p, Hash);
17 vector_init(&pp->
state);
22 vector_add(&pp->
state, (vtype)pps);
23 return pp;
24}
ANN void pos_ini(pos_t *pos)
ANN PPState * new_ppstate(MemPool p, const char *filename)
◆ new_ppstate()
ANN PPState * new_ppstate |
( |
MemPool | p, |
|
|
const char * | filename ) |
Definition at line 5 of file pp.c.
5 {
8 return ppstate;
9};
◆ pp_post()
static void pp_post |
( |
PP * | pp, |
|
|
void * | data ) |
|
static |
Definition at line 26 of file pp.c.
26 {
27 for (m_uint i = 1; i < vector_size(&pp->
state); ++i) {
28 void *ppstate = (
void *)vector_at(&pp->
state, i);
30 }
33 vector_clear(&pp->
state);
36}
ANN void clear_buffer(void *state, void *scan)
void macro_del(const Hash)