aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/gcc-interface/utils.c
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2012-04-30 07:50:07 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2012-04-30 07:50:07 +0000
commitf04b8d6927ad8374c40a3412eeda8f3be18e9fc0 (patch)
tree37a384e07b2e25f70080174ef8e49ccde609ad7d /gcc/ada/gcc-interface/utils.c
parent90137d8f2c5dfb3cb589e4b3497c63d7f810767e (diff)
downloadgcc-f04b8d6927ad8374c40a3412eeda8f3be18e9fc0.zip
gcc-f04b8d6927ad8374c40a3412eeda8f3be18e9fc0.tar.gz
gcc-f04b8d6927ad8374c40a3412eeda8f3be18e9fc0.tar.bz2
gigi.h (mark_out_of_scope): Delete.
* gcc-interface/gigi.h (mark_out_of_scope): Delete. (destroy_gnat_to_gnu): Declare. (destroy_dummy_type): Likewise. * gcc-interface/decl.c (mark_out_of_scope): Delete. * gcc-interface/utils.c (destroy_gnat_to_gnu): New function. (destroy_dummy_type): Likewise. * gcc-interface/trans.c (gnat_validate_uc_list): New variable. (gigi): Call validate_unchecked_conversion on gnat_validate_uc_list after the translation is completed.  Call destroy_gnat_to_gnu and destroy_dummy_type at the end. (Subprogram_Body_to_gnu): Do not call mark_out_of_scope. (gnat_to_gnu) <N_Block_Statement>: Likewise. <N_Validate_Unchecked_Conversion>: Do not process the node, only push it onto gnat_validate_uc_list. (validate_unchecked_conversion): New function. From-SVN: r186956
Diffstat (limited to 'gcc/ada/gcc-interface/utils.c')
-rw-r--r--gcc/ada/gcc-interface/utils.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/gcc/ada/gcc-interface/utils.c b/gcc/ada/gcc-interface/utils.c
index 41f83bf..123c3a5 100644
--- a/gcc/ada/gcc-interface/utils.c
+++ b/gcc/ada/gcc-interface/utils.c
@@ -231,6 +231,15 @@ init_gnat_to_gnu (void)
associate_gnat_to_gnu = ggc_alloc_cleared_vec_tree (max_gnat_nodes);
}
+/* Destroy the association of GNAT nodes to GCC trees. */
+
+void
+destroy_gnat_to_gnu (void)
+{
+ ggc_free (associate_gnat_to_gnu);
+ associate_gnat_to_gnu = NULL;
+}
+
/* GNAT_ENTITY is a GNAT tree node for an entity. Associate GNU_DECL, a GCC
tree node, with GNAT_ENTITY. If GNU_DECL is not a ..._DECL node, abort.
If NO_CHECK is true, the latter check is suppressed.
@@ -280,6 +289,15 @@ init_dummy_type (void)
dummy_node_table = ggc_alloc_cleared_vec_tree (max_gnat_nodes);
}
+/* Destroy the association of GNAT nodes to GCC trees as dummies. */
+
+void
+destroy_dummy_type (void)
+{
+ ggc_free (dummy_node_table);
+ dummy_node_table = NULL;
+}
+
/* Make a dummy type corresponding to GNAT_TYPE. */
tree