NAME ^

pastout.c - routines for emitting PAST

STATUS ^

Initial.

DATA STRUCTURE ^

The PAST back-end implements the emit_data data structure. Currently, only a single data member is used, to control the indention.

static int indent(emit_data *data)

increase the indention level

static int dedent(emit_data *data)

decrease the indention level

PAST VTABLE ENTRIES ^

static void past_init(struct emit_data *data)

Prints initializing PAST: ["past" => PMC 'PAST::Block' {]

static void past_block(struct emit_data *data)

Prints PAST for a block, including <source> and <pos> attributes.

static void past_source(emit_data *data, char *source)

TODO: Not yet documented!!!

static void past_position(emit_data *data, int pos)

TODO: Not yet documented!!!

static void past_close(struct emit_data *data)

Close down a PAST entity. The closing brace is printed, and the indention level is decremented.

static void past_name(struct emit_data *data, char *name)

Prints a PAST <name> entry.

static void past_stmts(struct emit_data *data)

Opens a PAST::Stmts node.

static void past_param(struct emit_data *data)

Generates a PAST::Var node and set its scope attribute to "parameter".

static void past_type(struct emit_data *data, char *type)

TODO: Not yet documented!!!

static void past_subflag(struct emit_data *data, int flag)

TODO: Not yet documented!!!

static void past_op(struct emit_data *data, char *op)

TODO: Not yet documented!!!

static void past_expr(struct emit_data *data, char *expr)

TODO: Not yet documented!!!

static void past_destroy(emit_data *data)

Destructor, close the outputfile if any, and free the emit_data structure.

pirvtable *init_past_vtable(char *outputfile)

Creates a vtable for the PAST emitting module, and then this vtable is set into the parser_state struct.


parrot