Up: Recording Imperative Program Parse Errors


4.4.1.1 Recording Imperative Program Parse Errors Example

Some struct x1f4_c1record_type record must be declared.

    struct x1f4_c1record_type c1record;

The error collector must be linked into the parsing context.

    struct x1f4_c1_type attributes;

    c1.bcollect_set.eerecord_data = &c1record;

Finally, the program parser must be indicated that it must record errors.

    status = x1f4_init_program(..., ..., X1f4_C1_BCOLLECT | ..., ...);