use b_plain use cz/vars cz_typedefs() for_vec(i, struct_union_class_template_protos, cstr) cstr l = *i cstr name = cstr_begins_with_word(l, "struct", "union") if name && token_type(*name) == NAME char *e = name + 1 tok_name(e) if *e == '\0' int struct_or_union_len = name - l while l[struct_or_union_len-1] == ' ' --struct_or_union_len vec_push(struct_union_typedefs, fformat("typedef %.*s %s %s", struct_or_union_len, l, name, name)) # *i = NULL # remove_null(struct_union_class_template_protos)