Entities of kind E_Subprogram_Body, used on bodies of subprograms for
which there is a separate declaration, have been added in the entities
linked from a scope in order to get the representation information on
their enclosed object and type declarations. Skip these entities in gigi.
gcc/ada/
* gcc-interface/trans.cc (elaborate_all_entities_for_package)
(process_freeze_entity): Skip entities of kind E_Subprogram_Body.
if (kind == E_Package_Body)
continue;
+ /* Skip subprogram bodies. */
+ if (kind == E_Subprogram_Body)
+ continue;
+
/* Skip limited views that point back to the main unit. */
if (IN (kind, Incomplete_Kind)
&& From_Limited_With (gnat_entity)
if (Is_Subprogram (gnat_entity) && Present (Interface_Alias (gnat_entity)))
return;
+ /* Skip subprogram bodies. */
+ if (kind == E_Subprogram_Body)
+ return;
+
/* Check for an old definition if this isn't an object with address clause,
since the saved GCC tree is the address expression in that case. */
gnu_old