Allow multiple variable declarations with a single type

This commit is contained in:
2025-02-15 10:26:04 +01:00
parent 82b3806fd2
commit b358f8ba27
7 changed files with 117 additions and 138 deletions

View File

@ -43,9 +43,9 @@ namespace gcc
tree string_ptr_type = build_pointer_type_for_mode(elna_char_type_node, VOIDmode, true);
elna_string_length_field_node = build_field(UNKNOWN_LOCATION,
elna_string_type_node, "length", elna_word_type_node);
elna_string_type_node, "length", build_qualified_type(elna_word_type_node, TYPE_QUAL_CONST));
elna_string_ptr_field_node = build_field(UNKNOWN_LOCATION,
elna_string_type_node, "ptr", string_ptr_type);
elna_string_type_node, "ptr", build_qualified_type(string_ptr_type, TYPE_QUAL_CONST));
TYPE_FIELDS(elna_string_type_node) = chainon(elna_string_ptr_field_node, elna_string_length_field_node);
layout_type(elna_string_type_node);