| 112 | } |
| 113 | |
| 114 | void hc_form_init(struct hc_form *f, |
| 115 | const struct hc_form_type *t, |
| 116 | const struct hc_sloc sloc, |
| 117 | struct hc_list *owner) { |
| 118 | f->type = t; |
| 119 | f->sloc = sloc; |
| 120 | |
| 121 | if (owner) { |
| 122 | hc_list_push_back(owner, &f->owner); |
| 123 | } else { |
| 124 | hc_list_init(&f->owner); |
| 125 | } |
| 126 | } |
| 127 | |
| 128 | void hc_form_emit(struct hc_form *f, struct hc_dsl *dsl) { |
| 129 | assert(f->type->emit); |
no test coverage detected