Commit a0bfea64 by Eric Botcazou Committed by Eric Botcazou

utils.c (update_pointer_to): In the unconstrained array case, merge the alias…

utils.c (update_pointer_to): In the unconstrained array case, merge the alias set of the old pointer type.

	* gcc-interfaces/utils.c (update_pointer_to): In the unconstrained
	array case, merge the alias set of the old pointer type.

From-SVN: r162488
parent 43afc047
2010-07-23 Eric Botcazou <ebotcazou@adacore.com> 2010-07-23 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interfaces/utils.c (update_pointer_to): In the unconstrained
array case, merge the alias set of the old pointer type.
2010-07-23 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/utils.c (gnat_types_compatible_p): Revert latest change * gcc-interface/utils.c (gnat_types_compatible_p): Revert latest change
and recurse only for multidimensional array types instead. and recurse only for multidimensional array types instead.
......
...@@ -3510,6 +3510,7 @@ update_pointer_to (tree old_type, tree new_type) ...@@ -3510,6 +3510,7 @@ update_pointer_to (tree old_type, tree new_type)
DECL_FIELD_CONTEXT (bounds_field) = new_ptr; DECL_FIELD_CONTEXT (bounds_field) = new_ptr;
for (t = new_ptr; t; last = t, t = TYPE_NEXT_VARIANT (t)) for (t = new_ptr; t; last = t, t = TYPE_NEXT_VARIANT (t))
TYPE_FIELDS (t) = TYPE_FIELDS (ptr); TYPE_FIELDS (t) = TYPE_FIELDS (ptr);
TYPE_ALIAS_SET (new_ptr) = TYPE_ALIAS_SET (ptr);
/* Chain PTR and its variants at the end. */ /* Chain PTR and its variants at the end. */
TYPE_NEXT_VARIANT (last) = TYPE_MAIN_VARIANT (ptr); TYPE_NEXT_VARIANT (last) = TYPE_MAIN_VARIANT (ptr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment