]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
re PR c++/5050 (template instantiation depth exceeds/maybe recursion problem)
authorAndrew Pinski <pinskia@physics.uc.edu>
Mon, 22 Dec 2003 21:00:55 +0000 (21:00 +0000)
committerAndrew Pinski <pinskia@gcc.gnu.org>
Mon, 22 Dec 2003 21:00:55 +0000 (13:00 -0800)
2003-12-22  Andrew Pinski  <pinskia@physics.uc.edu>

        PR c++/5050
        * tree.c (cp_start_inlining): Remove.
        (cp_end_inlining): Remove.
        * cp-lang.c (LANG_HOOKS_TREE_INLINING_START_INLINING): Do not define.
        (LANG_HOOKS_TREE_INLINING_END_INLINING): Do not define.
        * cp-tree.h (cp_start_inlining): Do not declare.
        (cp_end_inlining): Do not declare.

PR c++/5050
        * g++.dg/template/recurse1.C: New test.

From-SVN: r74950

gcc/cp/ChangeLog
gcc/cp/cp-lang.c
gcc/cp/cp-tree.h
gcc/cp/tree.c
gcc/testsuite/ChangeLog

index 9b404ec01b3222e4c07f71351f0b33e97c1ae0fe..a8cc0cd17d2f7c88fe078a5188470b472ef9481c 100644 (file)
@@ -1,3 +1,13 @@
+2003-12-22  Andrew Pinski  <pinskia@physics.uc.edu>
+
+       PR c++/5050
+       * tree.c (cp_start_inlining): Remove.
+       (cp_end_inlining): Remove.
+       * cp-lang.c (LANG_HOOKS_TREE_INLINING_START_INLINING): Do not define.
+       (LANG_HOOKS_TREE_INLINING_END_INLINING): Do not define.
+       * cp-tree.h (cp_start_inlining): Do not declare.
+       (cp_end_inlining): Do not declare.
+
 2003-12-21  Mark Mitchell  <mark@codesourcery.com>
 
        PR c++/11554
index 0d8a4e355b5fd5e4f88c0463698a7088ec8e242a..5eb2010ffd8c99db60cce4fa44c138a8015efead 100644 (file)
@@ -129,10 +129,6 @@ static bool cp_var_mod_type_p PARAMS ((tree));
 #define LANG_HOOKS_TREE_INLINING_ANON_AGGR_TYPE_P anon_aggr_type_p
 #undef LANG_HOOKS_TREE_INLINING_VAR_MOD_TYPE_P
 #define LANG_HOOKS_TREE_INLINING_VAR_MOD_TYPE_P cp_var_mod_type_p
-#undef LANG_HOOKS_TREE_INLINING_START_INLINING
-#define LANG_HOOKS_TREE_INLINING_START_INLINING cp_start_inlining
-#undef LANG_HOOKS_TREE_INLINING_END_INLINING
-#define LANG_HOOKS_TREE_INLINING_END_INLINING cp_end_inlining
 #undef LANG_HOOKS_TREE_DUMP_DUMP_TREE_FN
 #define LANG_HOOKS_TREE_DUMP_DUMP_TREE_FN cp_dump_tree
 #undef LANG_HOOKS_TREE_DUMP_TYPE_QUALS_FN
index d9388650dd5799a7fc18f3fdc98b63b3f93166ae..dcff3e95df52318124a684f05b4f63e5c3a365d2 100644 (file)
@@ -4379,8 +4379,6 @@ extern int cp_is_overload_p PARAMS ((tree));
 extern int cp_auto_var_in_fn_p PARAMS ((tree,tree));
 extern tree cp_copy_res_decl_for_inlining PARAMS ((tree, tree, tree, void*,
                                                   int*, void*));
-extern int cp_start_inlining                   PARAMS ((tree));
-extern void cp_end_inlining                    PARAMS ((tree));
 
 /* in typeck.c */
 extern int string_conv_p                       PARAMS ((tree, tree, int));
index 1551df051079fc0970b88fbd8315551c231fdb7e..90464b5f0d3ac5cbc67afd2fbdadac3ce8b17b18 100644 (file)
@@ -2302,30 +2302,6 @@ cp_copy_res_decl_for_inlining (result, fn, caller, decl_map_,
   return var;
 }
 
-/* Record that we're about to start inlining FN, and return nonzero if
-   that's OK.  Used for lang_hooks.tree_inlining.start_inlining.  */
-
-int
-cp_start_inlining (fn)
-     tree fn;
-{
-  if (DECL_TEMPLATE_INSTANTIATION (fn))
-    return push_tinst_level (fn);
-  else
-    return 1;
-}
-
-/* Record that we're done inlining FN.  Used for
-   lang_hooks.tree_inlining.end_inlining.  */
-
-void
-cp_end_inlining (fn)
-     tree fn ATTRIBUTE_UNUSED;
-{
-  if (DECL_TEMPLATE_INSTANTIATION (fn))
-    pop_tinst_level ();
-}
-
 /* Initialize tree.c.  */
 
 void
index f9042f49206e41a3f649f12c6218800da7823cea..d43d64f96c606a81b7f42cba7e216daba5309c4a 100644 (file)
@@ -1,3 +1,8 @@
+2003-12-22  Andrew Pinski  <pinskia@physics.uc.edu>
+
+       PR c++/5050
+       * g++.dg/template/recurse1.C: New test.
+
 2003-12-21  Mark Mitchell  <mark@codesourcery.com>
 
        PR c++/11554