print_tabs(fd, depth);
fprintf(fd, "</type_declarator>\n");
}
- if (!cds_list_empty(&node->u.type_declarator.u.nested.length)) {
+ if (node->u.type_declarator.u.nested.abstract_array) {
+ print_tabs(fd, depth);
+ fprintf(fd, "<length>\n");
+ print_tabs(fd, depth);
+ fprintf(fd, "</length>\n");
+ } else if (!cds_list_empty(&node->u.type_declarator.u.nested.length)) {
print_tabs(fd, depth);
fprintf(fd, "<length>\n");
cds_list_for_each_entry(iter, &node->u.type_declarator.u.nested.length,
print_tabs(fd, depth);
fprintf(fd, "</length>\n");
}
- if (node->u.type_declarator.u.nested.abstract_array) {
- print_tabs(fd, depth);
- fprintf(fd, "<length>\n");
- print_tabs(fd, depth);
- fprintf(fd, "</length>\n");
- }
if (node->u.type_declarator.bitfield_len) {
print_tabs(fd, depth);
fprintf(fd, "<bitfield_len>\n");