+2004-05-01 Gabriel Dos Reis <gdr@integrable-solutions.net>
+
+ Backport from gcc-3_4-branch
+ 2004-03-30 Mark Mitchell <mark@codesourcery.com>
+ Jakub Jelinek <jakub@redhat.com>
+ PR c++/14763
+ * pt.c (tsubst_default_argument): Clear current_function_decl.
+ * decl2.c (mark_used): Don't segfault if cfun != NULL but
+ current_function_decl == NULL.
+
2004-05-01 Gabriel Dos Reis <gdr@integrable-solutions.net>
Backport from gcc-3_4-branch:
generate its body to find that out. */
|| TREE_NOTHROW (decl)
|| !cfun
+ || !current_function_decl
/* If we already know the current function can't throw,
then we don't need to work hard to prove it. */
|| TREE_NOTHROW (current_function_decl)
/* FN is already the desired FUNCTION_DECL. */
push_access_scope (fn);
+ /* The default argument expression should not be considered to be
+ within the scope of FN. Since push_access_scope sets
+ current_function_decl, we must explicitly clear it here. */
+ current_function_decl = NULL_TREE;
arg = tsubst_expr (arg, DECL_TI_ARGS (fn),
tf_error | tf_warning, NULL_TREE);