This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Ada PATCH] don't modify record fields in update_pointer_to


> I've redone the patch (attached) based on the tree as of today.  It
> bootstraps and does not introduce any new failures in the testsuite.

Great!

> I didn't find gnat_desig_equiv anywhere, and XUT is also built using
> gnat_desig_type. So I didn't make any changes here.

Hum...

		TYPE_OBJECT_RECORD_TYPE (gnu_old) = make_node (RECORD_TYPE);
		TYPE_NAME (TYPE_OBJECT_RECORD_TYPE (gnu_old))
		  = concat_id_with_name (get_entity_name (gnat_desig_equiv),
					 "XUT");
		TYPE_DUMMY_P (TYPE_OBJECT_RECORD_TYPE (gnu_old)) = 1;

> The first line is redundant: the field already has this type.  Just to be
> sure I added an assertion that this was true, and then bootstrapped and
> ran the ACATS and gnat test suites - the assertion never fired.  You might
> also wonder why the second line is not redundant: that's because the array
> type was modified a few lines above (gnat_substitute_in_type).

OK, a comment would not be superfluous then because that's not trivial.

-- 
Eric Botcazou


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]