OSDN Git Service

* cp-tree.h (language_function): Remove x_last_dtor_insn and
[pf3gnuchains/gcc-fork.git] / gcc / cp / cp-tree.h
index 50d28ca..eba8e02 100644 (file)
@@ -20,6 +20,8 @@ the Free Software Foundation, 59 Temple Place - Suite 330,
 Boston, MA 02111-1307, USA.  */
 
 #include "c-common.h"
+#include "function.h"
+#include "varray.h"
 
 #ifndef _CP_TREE_H
 #define _CP_TREE_H
@@ -35,30 +37,39 @@ Boston, MA 02111-1307, USA.  */
       IDENTIFIER_MARKED (used by search routines).
       LOCAL_BINDING_P (in CPLUS_BINDING)
       ICS_USER_FLAG (in _CONV)
+      CLEANUP_P (in TRY_BLOCK)
+      AGGR_INIT_VIA_CTOR_P (in AGGR_INIT_EXPR)
+      SCOPE_BEGIN_P (in SCOPE_STMT)
    1: IDENTIFIER_VIRTUAL_P.
       TI_PENDING_TEMPLATE_FLAG.
       TEMPLATE_PARMS_FOR_INLINE.
       DELETE_EXPR_USE_VEC (in DELETE_EXPR).
       (TREE_CALLS_NEW) (in _EXPR or _REF) (commented-out).
       TYPE_USES_COMPLEX_INHERITANCE (in _TYPE).
-      C_DECLARED_LABEL_FLAG.
+      C_DECLARED_LABEL_FLAG (in LABEL_DECL)
       INHERITED_VALUE_BINDING_P (in CPLUS_BINDING)
       BASELINK_P (in TREE_LIST)
       ICS_ELLIPSIS_FLAG (in _CONV)
+      STMT_IS_FULL_EXPR_P (in _STMT)
    2: IDENTIFIER_OPNAME_P.
       BINFO_VBASE_MARKED.
       BINFO_FIELDS_MARKED.
       TYPE_VIRTUAL_P.
       ICS_THIS_FLAG (in _CONV)
+      STMT_LINENO_FOR_FN_P (in _STMT)
+      BINDING_HAS_LEVEL_P (in CPLUS_BINDING)
    3: TYPE_USES_VIRTUAL_BASECLASSES (in a class TYPE).
       BINFO_VTABLE_PATH_MARKED.
       BINFO_PUSHDECLS_MARKED.
       (TREE_REFERENCE_EXPR) (in NON_LVALUE_EXPR) (commented-out).
       ICS_BAD_FLAG (in _CONV)
+      FN_TRY_BLOCK_P (in TRY_BLOCK)
+      SCOPE_NULLIFIED_P (in SCOPE_STMT)
    4: BINFO_NEW_VTABLE_MARKED.
       TREE_HAS_CONSTRUCTOR (in INDIRECT_REF, SAVE_EXPR, CONSTRUCTOR,
           or FIELD_DECL).
       NEED_TEMPORARY_P (in REF_BIND, BASE_CONV)
+      SCOPE_PARTIAL_P (in SCOPE_STMT)
    5: Not used.
    6: Not used.
 
@@ -77,6 +88,7 @@ Boston, MA 02111-1307, USA.  */
    1: C_TYPEDEF_EXPLICITLY_SIGNED (in TYPE_DECL).
       DECL_TEMPLATE_INSTANTIATED (in a VAR_DECL or a FUNCTION_DECL)
    2: DECL_THIS_EXTERN (in VAR_DECL or FUNCTION_DECL).
+      DECL_IMPLICIT_TYPEDEF_P (in a TYPE_DECL)
    3: DECL_IN_AGGR_P.
    4: DECL_MAYBE_TEMPLATE.
    5: DECL_INTERFACE_KNOWN.
@@ -98,7 +110,56 @@ Boston, MA 02111-1307, USA.  */
 
    DECL_SAVED_INSNS/DECL_FIELD_SIZE
      For a static VAR_DECL, this is DECL_INIT_PRIORITY.
-*/
+
+   BINFO_VIRTUALS
+     For a binfo, this is a TREE_LIST.  The TREE_PURPOSE of each node
+     gives the amount by which to adjust the `this' pointer when
+     calling the function.  The TREE_VALUE is the declaration for the 
+     virtual function itself.  When CLASSTYPE_COM_INTERFACE_P does not
+     hold, the first entry does not have a TREE_VALUE; it is just an
+     offset.
+
+   DECL_ARGUMENTS
+     For a VAR_DECL this is DECL_ANON_UNION_ELEMS.  */
+
+/* Language-specific tree checkers. */
+
+#if defined ENABLE_CHECKING && HAVE_GCC_VERSION(2,7)
+
+#define VAR_OR_FUNCTION_DECL_CHECK(NODE)                       \
+({  const tree __t = NODE;                                     \
+    enum tree_code __c = TREE_CODE(__t);                       \
+    if (__c != VAR_DECL && __c != FUNCTION_DECL)               \
+      tree_check_failed (__t, VAR_DECL, __FILE__,              \
+                        __LINE__, __PRETTY_FUNCTION__);        \
+    __t; })
+
+#define VAR_TEMPL_TYPE_OR_FUNCTION_DECL_CHECK(NODE)            \
+({  const tree __t = NODE;                                     \
+    enum tree_code __c = TREE_CODE(__t);                       \
+    if (__c != VAR_DECL                                        \
+       && __c != FUNCTION_DECL                                 \
+       && __c != TYPE_DECL                                     \
+       && __c != TEMPLATE_DECL)                                \
+      tree_check_failed (__t, VAR_DECL, __FILE__,              \
+                        __LINE__, __PRETTY_FUNCTION__);        \
+    __t; })
+
+#define RECORD_OR_UNION_TYPE_CHECK(NODE)                       \
+({  const tree __t = NODE;                                     \
+    enum tree_code __c = TREE_CODE(__t);                       \
+    if (__c != RECORD_TYPE && __c != UNION_TYPE)               \
+      tree_check_failed (__t, RECORD_TYPE, __FILE__,           \
+                        __LINE__, __PRETTY_FUNCTION__);        \
+    __t; })
+
+#else /* not ENABLE_CHECKING, or not gcc */
+
+#define VAR_OR_FUNCTION_DECL_CHECK(NODE)       NODE
+#define VAR_TEMPL_TYPE_OR_FUNCTION_DECL_CHECK(NODE)    NODE
+#define RECORD_OR_UNION_TYPE_CHECK(NODE)       NODE
+
+#endif
 
 /* Language-dependent contents of an identifier.  */
 
@@ -112,6 +173,9 @@ struct lang_identifier
   struct lang_id2 *x;
 };
 
+#define LANG_IDENTIFIER_CAST(NODE) \
+       ((struct lang_identifier*)IDENTIFIER_NODE_CHECK (NODE))
+
 struct lang_id2
 {
   tree label_value, implicit_decl;
@@ -127,8 +191,6 @@ typedef struct
 typedef struct 
 {
   char common[sizeof (struct tree_common)];
-  struct rtx_def *rtl; /* Unused, but required to match up with what
-                          the middle-end expects.  */
   HOST_WIDE_INT index;
   HOST_WIDE_INT level;
   HOST_WIDE_INT orig_level;
@@ -138,6 +200,9 @@ typedef struct
 typedef struct ptrmem_cst
 {
   char common[sizeof (struct tree_common)];
+  /* This isn't used, but the middle-end expects all constants to have 
+     this field.  */
+  struct rtx_def *rtl;
   tree member;
 }* ptrmem_cst_t;
 
@@ -154,11 +219,14 @@ typedef struct ptrmem_cst
    _TYPE node, or a NAMESPACE_DECL.)  This macro should be used only
    for namespace-level bindings; on the IDENTIFIER_BINDING list
    BINDING_LEVEL is used instead.  */
-#define BINDING_SCOPE(NODE) (((struct tree_binding*)NODE)->scope.scope)
+#define BINDING_SCOPE(NODE) (((struct tree_binding*)CPLUS_BINDING_CHECK (NODE))->scope.scope)
+
+/* Nonzero if NODE has BINDING_LEVEL, rather than BINDING_SCOPE.  */
+#define BINDING_HAS_LEVEL_P(NODE) TREE_LANG_FLAG_2 ((NODE))
 
 /* This is the declaration bound to the name. Possible values:
    variable, overloaded function, namespace, template, enumerator.  */
-#define BINDING_VALUE(NODE)    (((struct tree_binding*)NODE)->value)
+#define BINDING_VALUE(NODE)    (((struct tree_binding*)CPLUS_BINDING_CHECK (NODE))->value)
 
 /* If name is bound to a type, this is the type (struct, union, enum).  */
 #define BINDING_TYPE(NODE)     TREE_TYPE(NODE)
@@ -183,7 +251,7 @@ struct tree_binding
 };
 
 /* The overloaded FUNCTION_DECL. */
-#define OVL_FUNCTION(NODE)   (((struct tree_overload*)NODE)->function)
+#define OVL_FUNCTION(NODE)   (((struct tree_overload*)OVERLOAD_CHECK (NODE))->function)
 #define OVL_CHAIN(NODE)      TREE_CHAIN(NODE)
 /* Polymorphic access to FUNCTION and CHAIN. */
 #define OVL_CURRENT(NODE)     \
@@ -205,12 +273,12 @@ struct tree_overload
    indicating a particular base class, and whose TREE_VALUE is a
    (possibly overloaded) function from that base class.  */
 #define BASELINK_P(NODE) \
-  (TREE_CODE ((NODE)) == TREE_LIST && TREE_LANG_FLAG_1 ((NODE)))
+  (TREE_CODE (NODE) == TREE_LIST && TREE_LANG_FLAG_1 (NODE))
 #define SET_BASELINK_P(NODE) \
-  (TREE_LANG_FLAG_1 ((NODE)) = 1)
+  (TREE_LANG_FLAG_1 (NODE) = 1)
 
-#define WRAPPER_PTR(NODE) (((struct tree_wrapper*)NODE)->u.ptr)
-#define WRAPPER_INT(NODE) (((struct tree_wrapper*)NODE)->u.i)
+#define WRAPPER_PTR(NODE) (((struct tree_wrapper*)WRAPPER_CHECK (NODE))->u.ptr)
+#define WRAPPER_INT(NODE) (((struct tree_wrapper*)WRAPPER_CHECK (NODE))->u.i)
 
 struct tree_wrapper
 {
@@ -221,8 +289,8 @@ struct tree_wrapper
   } u;
 };
 
-#define SRCLOC_FILE(NODE) (((struct tree_srcloc*)NODE)->filename)
-#define SRCLOC_LINE(NODE) (((struct tree_srcloc*)NODE)->linenum)
+#define SRCLOC_FILE(NODE) (((struct tree_srcloc*)SRCLOC_CHECK (NODE))->filename)
+#define SRCLOC_LINE(NODE) (((struct tree_srcloc*)SRCLOC_CHECK (NODE))->linenum)
 struct tree_srcloc
 {
   char common[sizeof (struct tree_common)];
@@ -237,9 +305,9 @@ struct tree_srcloc
 /* Macros for access to language-specific slots in an identifier.  */
 
 #define IDENTIFIER_NAMESPACE_BINDINGS(NODE)    \
-  (((struct lang_identifier *)(NODE))->namespace_bindings)
+  (LANG_IDENTIFIER_CAST (NODE)->namespace_bindings)
 #define IDENTIFIER_TEMPLATE(NODE)      \
-  (((struct lang_identifier *)(NODE))->class_template_info)
+  (LANG_IDENTIFIER_CAST (NODE)->class_template_info)
 
 /* The IDENTIFIER_BINDING is the innermost CPLUS_BINDING for the
     identifier.  It's TREE_CHAIN is the next outermost binding.  Each
@@ -249,7 +317,7 @@ struct tree_srcloc
     and such.)  You can use BINDING_SCOPE or BINDING_LEVEL to
     determine the scope that bound the name.  */
 #define IDENTIFIER_BINDING(NODE) \
-  (((struct lang_identifier*) (NODE))->bindings)
+  (LANG_IDENTIFIER_CAST (NODE)->bindings)
 
 /* The IDENTIFIER_VALUE is the value of the IDENTIFIER_BINDING, or
    NULL_TREE if there is no binding.  */
@@ -264,7 +332,7 @@ struct tree_srcloc
    IDENTIFIER_BINDINGs list, so any time that this is non-NULL so is
    IDENTIFIER_BINDING.  */
 #define IDENTIFIER_CLASS_VALUE(NODE) \
-  (((struct lang_identifier *) (NODE))->class_value)
+  (LANG_IDENTIFIER_CAST (NODE)->class_value)
 
 /* The amount of time used by the file whose special "time identifier"
    is NODE, represented as an INTEGER_CST.  See get_time_identifier.  */
@@ -284,14 +352,15 @@ struct tree_srcloc
 #define SET_IDENTIFIER_TYPE_VALUE(NODE,TYPE) (TREE_TYPE (NODE) = TYPE)
 #define IDENTIFIER_HAS_TYPE_VALUE(NODE) (IDENTIFIER_TYPE_VALUE (NODE) ? 1 : 0)
 
-#define LANG_ID_FIELD(NAME,NODE) \
-  (((struct lang_identifier *)(NODE))->x \
-   ? ((struct lang_identifier *)(NODE))->x->NAME : 0)
-#define SET_LANG_ID(NODE,VALUE,NAME) \
-  (((struct lang_identifier *)(NODE))->x == 0                              \
-   ? ((struct lang_identifier *)(NODE))->x                                 \
-      = (struct lang_id2 *)perm_calloc (1, sizeof (struct lang_id2)) : 0,   \
-   ((struct lang_identifier *)(NODE))->x->NAME = (VALUE))
+#define LANG_ID_FIELD(NAME,NODE)                       \
+  (LANG_IDENTIFIER_CAST (NODE)->x                      \
+   ? LANG_IDENTIFIER_CAST (NODE)->x->NAME : 0)  
+
+#define SET_LANG_ID(NODE,VALUE,NAME)                                     \
+  (LANG_IDENTIFIER_CAST (NODE)->x == 0                           \
+   ? LANG_IDENTIFIER_CAST (NODE)->x                                      \
+      = (struct lang_id2 *)perm_calloc (1, sizeof (struct lang_id2)) : 0, \
+   LANG_IDENTIFIER_CAST (NODE)->x->NAME = (VALUE))
 
 #define IDENTIFIER_LABEL_VALUE(NODE)       LANG_ID_FIELD(label_value, NODE)
 #define SET_IDENTIFIER_LABEL_VALUE(NODE,VALUE)   \
@@ -308,7 +377,8 @@ struct tree_srcloc
 
 #define IDENTIFIER_VIRTUAL_P(NODE) TREE_LANG_FLAG_1(NODE)
 
-/* Nonzero if this identifier is the prefix for a mangled C++ operator name.  */
+/* Nonzero if this identifier is the prefix for a mangled C++ operator
+   name.  */
 #define IDENTIFIER_OPNAME_P(NODE) TREE_LANG_FLAG_2(NODE)
 
 /* Nonzero if this identifier is the name of a type-conversion
@@ -351,6 +421,7 @@ enum cp_tree_index
     CPTI_WCHAR_DECL,
     CPTI_VTABLE_ENTRY_TYPE,
     CPTI_DELTA_TYPE,
+    CPTI_CLEANUP_TYPE,
 
     CPTI_TP_DESC_TYPE,
     CPTI_ACCESS_MODE_TYPE,
@@ -369,9 +440,6 @@ enum cp_tree_index
     CPTI_UNION_TYPE,
     CPTI_ENUM_TYPE,
     CPTI_UNKNOWN_TYPE,
-    CPTI_OPAQUE_TYPE,
-    CPTI_SIGNATURE_TYPE,
-    CPTI_SIGTABLE_ENTRY_TYPE,
     CPTI_VTBL_TYPE,
     CPTI_VTBL_PTR_TYPE,
     CPTI_STD,
@@ -381,6 +449,38 @@ enum cp_tree_index
     CPTI_ABORT_FNDECL,
     CPTI_GLOBAL_DELETE_FNDECL,
 
+    CPTI_ACCESS_DEFAULT,
+    CPTI_ACCESS_PUBLIC,
+    CPTI_ACCESS_PROTECTED,
+    CPTI_ACCESS_PRIVATE,
+    CPTI_ACCESS_DEFAULT_VIRTUAL,
+    CPTI_ACCESS_PUBLIC_VIRTUAL,
+    CPTI_ACCESS_PROTECTED_VIRTUAL,
+    CPTI_ACCESS_PRIVATE_VIRTUAL,
+
+    CPTI_CTOR_IDENTIFIER,
+    CPTI_DELTA2_IDENTIFIER,
+    CPTI_DELTA_IDENTIFIER,
+    CPTI_DTOR_IDENTIFIER,
+    CPTI_IN_CHARGE_IDENTIFIER,
+    CPTI_INDEX_IDENTIFIER,
+    CPTI_NELTS_IDENTIFIER,
+    CPTI_THIS_IDENTIFIER,
+    CPTI_PFN_IDENTIFIER,
+    CPTI_PFN_OR_DELTA2_IDENTIFIER,
+    CPTI_VPTR_IDENTIFIER,
+
+    CPTI_LANG_NAME_C,
+    CPTI_LANG_NAME_CPLUSPLUS,
+    CPTI_LANG_NAME_JAVA,
+
+    CPTI_EMPTY_EXCEPT_SPEC,
+    CPTI_NULL,
+    CPTI_JCLASS,
+    CPTI_MINUS_ONE,
+    CPTI_TERMINATE,
+    CPTI_ATEXIT,
+
     CPTI_MAX
 };
 
@@ -415,9 +515,6 @@ extern tree cp_global_trees[CPTI_MAX];
 #define union_type_node                        cp_global_trees[CPTI_UNION_TYPE]
 #define enum_type_node                 cp_global_trees[CPTI_ENUM_TYPE]
 #define unknown_type_node              cp_global_trees[CPTI_UNKNOWN_TYPE]
-#define opaque_type_node               cp_global_trees[CPTI_OPAQUE_TYPE]
-#define signature_type_node            cp_global_trees[CPTI_SIGNATURE_TYPE]
-#define sigtable_entry_type            cp_global_trees[CPTI_SIGTABLE_ENTRY_TYPE]
 #define vtbl_type_node                 cp_global_trees[CPTI_VTBL_TYPE]
 #define vtbl_ptr_type_node             cp_global_trees[CPTI_VTBL_PTR_TYPE]
 #define std_node                       cp_global_trees[CPTI_STD]
@@ -427,11 +524,315 @@ extern tree cp_global_trees[CPTI_MAX];
 #define abort_fndecl                   cp_global_trees[CPTI_ABORT_FNDECL]
 #define global_delete_fndecl           cp_global_trees[CPTI_GLOBAL_DELETE_FNDECL]
 
-extern int current_function_returns_value;
-extern int current_function_returns_null;
-extern tree current_function_return_value;
+/* Define the sets of attributes that member functions and baseclasses
+   can have.  These are sensible combinations of {public,private,protected}
+   cross {virtual,non-virtual}.  */
+
+#define access_default_node             cp_global_trees[CPTI_ACCESS_DEFAULT]
+#define access_public_node              cp_global_trees[CPTI_ACCESS_PUBLIC]
+#define access_protected_node           cp_global_trees[CPTI_ACCESS_PROTECTED]
+#define access_private_node             cp_global_trees[CPTI_ACCESS_PRIVATE]
+#define access_default_virtual_node     cp_global_trees[CPTI_ACCESS_DEFAULT_VIRTUAL]
+#define access_public_virtual_node      cp_global_trees[CPTI_ACCESS_PUBLIC_VIRTUAL]
+#define access_protected_virtual_node   cp_global_trees[CPTI_ACCESS_PROTECTED_VIRTUAL]
+#define access_private_virtual_node     cp_global_trees[CPTI_ACCESS_PRIVATE_VIRTUAL]
+
+/* We cache these tree nodes so as to call get_identifier less
+   frequently.  */
+
+#define ctor_identifier                 cp_global_trees[CPTI_CTOR_IDENTIFIER]
+#define delta2_identifier               cp_global_trees[CPTI_DELTA2_IDENTIFIER]
+#define delta_identifier                cp_global_trees[CPTI_DELTA_IDENTIFIER]
+#define dtor_identifier                 cp_global_trees[CPTI_DTOR_IDENTIFIER]
+#define in_charge_identifier            cp_global_trees[CPTI_IN_CHARGE_IDENTIFIER]
+#define index_identifier                cp_global_trees[CPTI_INDEX_IDENTIFIER]
+#define nelts_identifier                cp_global_trees[CPTI_NELTS_IDENTIFIER]
+#define this_identifier                 cp_global_trees[CPTI_THIS_IDENTIFIER]
+#define pfn_identifier                  cp_global_trees[CPTI_PFN_IDENTIFIER]
+#define pfn_or_delta2_identifier        cp_global_trees[CPTI_PFN_OR_DELTA2_IDENTIFIER]
+#define vptr_identifier                 cp_global_trees[CPTI_VPTR_IDENTIFIER]
+
+#define lang_name_c                     cp_global_trees[CPTI_LANG_NAME_C]
+#define lang_name_cplusplus             cp_global_trees[CPTI_LANG_NAME_CPLUSPLUS]
+#define lang_name_java                  cp_global_trees[CPTI_LANG_NAME_JAVA]
+
+/* Exception specifier used for throw().  */
+#define empty_except_spec               cp_global_trees[CPTI_EMPTY_EXCEPT_SPEC]
+
+/* The node for `__null'.  */
+#define null_node                       cp_global_trees[CPTI_NULL]
+
+/* If non-NULL, a POINTER_TYPE equivalent to (java::lang::Class*). */
+#define jclass_node                     cp_global_trees[CPTI_JCLASS]
+
+/* A node for `(int) -1'.  */
+#define minus_one_node                  cp_global_trees[CPTI_MINUS_ONE]
+
+/* The declaration for `std::terminate'.  */
+#define terminate_node                  cp_global_trees[CPTI_TERMINATE]
+
+/* The declaration for `std::atexit'.  */
+#define atexit_node                     cp_global_trees[CPTI_ATEXIT]
+
+/* The type of a destructor.  */
+#define cleanup_type                    cp_global_trees[CPTI_CLEANUP_TYPE]
+
+/* Global state.  */
+
+struct stmt_tree {
+  tree x_last_stmt;
+  tree x_last_expr_type;
+  int stmts_are_full_exprs_p; 
+};
+
+struct saved_scope {
+  tree old_bindings;
+  tree old_namespace;
+  tree class_name;
+  tree class_type;
+  tree access_specifier;
+  tree function_decl;
+  varray_type lang_base;
+  tree *lang_stack;
+  tree lang_name;
+  tree x_function_parms;
+  tree template_parms;
+  tree x_previous_class_type;
+  tree x_previous_class_values;
+  tree x_saved_tree;
+
+  HOST_WIDE_INT x_processing_template_decl;
+  int x_processing_specialization;
+  int x_processing_explicit_instantiation;
+  int need_pop_function_context;
+
+  struct stmt_tree x_stmt_tree;
+
+  struct binding_level *class_bindings;
+  struct binding_level *bindings;
+
+  struct saved_scope *prev;
+};
+
+/* The current open namespace.  */
+
+#define current_namespace scope_chain->old_namespace
+
+/* IDENTIFIER_NODE: name of current class */
+
+#define current_class_name scope_chain->class_name
+
+/* _TYPE: the type of the current class */
+
+#define current_class_type scope_chain->class_type
+
+/* When parsing a class definition, the access specifier most recently
+   given by the user, or, if no access specifier was given, the
+   default value appropriate for the kind of class (i.e., struct,
+   class, or union).  */
+
+#define current_access_specifier scope_chain->access_specifier
+
+/* Pointer to the top of the language name stack.  */
+
+#define current_lang_stack scope_chain->lang_stack
+#define current_lang_base scope_chain->lang_base
+#define current_lang_name scope_chain->lang_name
+
+/* Parsing a function declarator leaves a list of parameter names
+   or a chain or parameter decls here.  */
+
+#define current_function_parms scope_chain->x_function_parms
+#define current_template_parms scope_chain->template_parms
+
+#define processing_template_decl scope_chain->x_processing_template_decl
+#define processing_specialization scope_chain->x_processing_specialization
+#define processing_explicit_instantiation scope_chain->x_processing_explicit_instantiation
+
+/* _TYPE: the previous type that was a class */
+
+#define previous_class_type scope_chain->x_previous_class_type
+
+/* This is a copy of the class_shadowed list of the previous class
+   binding contour when at global scope.  It's used to reset
+   IDENTIFIER_CLASS_VALUEs when entering another class scope (i.e. a
+   cache miss).  */
+
+#define previous_class_values scope_chain->x_previous_class_values
+
+extern struct saved_scope *scope_chain;
+
+/* Global state pertinent to the current function.  */
+
+struct language_function
+{
+  tree x_named_labels;
+  tree x_ctor_label;
+  tree x_dtor_label;
+  tree x_base_init_list;
+  tree x_member_init_list;
+  tree x_current_class_ptr;
+  tree x_current_class_ref;
+  tree x_eh_spec_try_block;
+  tree x_scope_stmt_stack;
+  tree x_in_charge_parm;
+
+  tree *x_vcalls_possible_p;
+
+  struct rtx_def *x_result_rtx;
+
+  int returns_value;
+  int returns_null;
+  int parms_stored;
+  int temp_name_counter;
+  int in_function_try_handler;
+  int x_expanding_p;
+  int name_declared;
+  int vtbls_set_up_p;
+
+  struct stmt_tree x_stmt_tree;
+
+  struct named_label_list *x_named_label_uses;
+  struct binding_level *bindings;
+
+  const char *cannot_inline;
+};
+
+/* The current C++-specific per-function global variables.  */
+
+#define cp_function_chain (current_function->language)
+
+/* In a destructor, the point at which all derived class destroying
+   has been done, just before any base class destroying will be done.  */
+
+#define dtor_label cp_function_chain->x_dtor_label
 
-extern tree current_namespace;
+/* In a constructor, the point at which we are ready to return
+   the pointer to the initialized object.  */
+
+#define ctor_label cp_function_chain->x_ctor_label
+
+/* In C++, structures with well-defined constructors are initialized by
+   those constructors, unasked.  CURRENT_BASE_INIT_LIST
+   holds a list of stmts for a BASE_INIT term in the grammar.
+   This list has one element for each base class which must be
+   initialized.  The list elements are [basename, init], with
+   type basetype.  This allows the possibly anachronistic form
+   (assuming d : a, b, c) "d (int a) : c(a+5), b (a-4), a (a+3)"
+   where each successive term can be handed down the constructor
+   line.  Perhaps this was not intended.  */
+
+#define current_base_init_list cp_function_chain->x_base_init_list
+#define current_member_init_list cp_function_chain->x_member_init_list
+
+/* When we're processing a member function, current_class_ptr is the
+   PARM_DECL for the `this' pointer.  The current_class_ref is an
+   expression for `*this'.  */
+
+#define current_class_ptr \
+  (current_function ? cp_function_chain->x_current_class_ptr : NULL_TREE)
+#define current_class_ref \
+  (current_function ? cp_function_chain->x_current_class_ref : NULL_TREE)
+
+/* Information about the current statement tree.  */
+
+#define current_stmt_tree                      \
+  (current_function                            \
+   ? &cp_function_chain->x_stmt_tree           \
+   : &scope_chain->x_stmt_tree)
+
+/* When building a statement-tree, this is the last statement added to
+   the tree.  */
+
+#define last_tree current_stmt_tree->x_last_stmt
+
+/* The type of the last expression-statement we have seen.  This is
+   required because the type of a statement-expression is the type of
+   the last expression statement.  */
+
+#define last_expr_type current_stmt_tree->x_last_expr_type
+
+/* The TRY_BLOCK for the exception-specifiers for the current
+   function, if any.  */
+
+#define current_eh_spec_try_block cp_function_chain->x_eh_spec_try_block
+
+/* The stack of SCOPE_STMTs for the current function.  */
+
+#define current_scope_stmt_stack cp_function_chain->x_scope_stmt_stack
+
+/* The `__in_chrg' parameter for the current function.  Only used for
+   destructors.  */
+
+#define current_in_charge_parm cp_function_chain->x_in_charge_parm
+
+/* In destructors, this is a pointer to a condition in an
+   if-statement.  If the pointed-to value is boolean_true_node, then
+   there may be virtual function calls in this destructor.  */
+
+#define current_vcalls_possible_p cp_function_chain->x_vcalls_possible_p
+
+/* Set to 0 at beginning of a function definition, set to 1 if
+   a return statement that specifies a return value is seen.  */
+
+#define current_function_returns_value cp_function_chain->returns_value
+
+/* Set to 0 at beginning of a function definition, set to 1 if
+   a return statement with no argument is seen.  */
+
+#define current_function_returns_null cp_function_chain->returns_null
+
+#define current_function_just_assigned_this \
+  cp_function_chain->just_assigned_this
+
+#define current_function_parms_stored \
+  cp_function_chain->parms_stored
+
+/* Non-zero if we have already declared __FUNCTION__ (and related
+   variables) in the current function.  */
+
+#define current_function_name_declared \
+  cp_function_chain->name_declared
+
+/* Nonzero if we have already generated code to initialize virtual
+   function tables in this function.  */
+
+#define vtbls_set_up_p cp_function_chain->vtbls_set_up_p
+
+/* Used to help generate temporary names which are unique within
+   a function.  Reset to 0 by start_function.  */
+
+#define temp_name_counter cp_function_chain->temp_name_counter
+
+/* Non-zero if we should generate RTL for functions that we process.
+   When this is zero, we just accumulate tree structure, without
+   interacting with the back end.  */
+
+#define expanding_p cp_function_chain->x_expanding_p
+
+/* Non-zero if we are in the semantic analysis phase for the current
+   function.  */
+
+#define doing_semantic_analysis_p() (!expanding_p)
+
+/* Non-zero if we should treat statements as full expressions.  In
+   particular, this variable is no-zero if at the end of a statement
+   we should destroy any temporaries created during that statement.
+   Similarly, if, at the end of a block, we should destroy any local
+   variables in this block.  Normally, this variable is non-zero,
+   since those are the normal semantics of C++.
+
+   However, in order to represent aggregate initialization code as
+   tree structure, we use statement-expressions.  The statements
+   within the statement expression should not result in cleanups being
+   run until the entire enclosing statement is complete.  */
+
+#define stmts_are_full_exprs_p \
+  current_stmt_tree->stmts_are_full_exprs_p
+
+#define in_function_try_handler cp_function_chain->in_function_try_handler
+
+extern tree current_function_return_value;
 extern tree global_namespace;
 
 extern tree ridpointers[];
@@ -482,6 +883,11 @@ extern int warn_return_type;
 
 extern int flag_const_strings;
 
+/* If non-NULL, dump the tree structure for the entire translation
+   unit to this file.  */
+
+extern char *flag_dump_translation_unit;
+
 /* Nonzero means warn about deprecated conversion from string constant to
    `char *'.  */
 
@@ -509,6 +915,10 @@ extern int warn_missing_braces;
 
 extern int warn_sign_compare;
 
+/* Warn about testing equality of floating point numbers. */
+
+extern int warn_float_equal;
+
 /* Warn about a subscript that has type char.  */
 
 extern int warn_char_subscripts;
@@ -574,10 +984,6 @@ extern int flag_elide_constructors;
 
 extern int flag_ansi;
 
-/* Nonzero means recognize and handle signature language constructs.  */
-
-extern int flag_handle_signatures;
-
 /* Nonzero means that member functions defined in class scope are
    inline by default.  */
 
@@ -590,11 +996,19 @@ extern int name_mangling_version;
 /* Nonzero means that guiding declarations are allowed.  */
 extern int flag_guiding_decls;
 
+/* Nonzero if wchar_t should be `unsigned short' instead of whatever it
+   would normally be, for use with WINE.  */
+extern int flag_short_wchar;
+
 /* Nonzero if squashed mangling is to be performed. 
    This uses the B and K codes to reference previously seen class types 
    and class qualifiers.       */
 extern int flag_do_squangling;
 
+/* Nonzero means generate separate instantiation control files and juggle
+   them at link time.  */
+extern int flag_use_repository;
+
 /* Nonzero if we want to issue diagnostics that the standard says are not
    required.  */
 extern int flag_optional_diags;
@@ -614,6 +1028,12 @@ extern int flag_permissive;
 
 extern int flag_access_control;
 
+/* If this variable is defined to a non-NULL value, it will be called
+   after the file has been completely parsed.  The argument will be
+   the GLOBAL_NAMESPACE.  */
+
+extern void (*back_end_hook) PROTO((tree));
+
 \f
 /* C++ language-specific tree codes.  */
 #define DEFTREECODE(SYM, NAME, TYPE, LENGTH) SYM,
@@ -663,7 +1083,7 @@ enum languages { lang_c, lang_cplusplus, lang_java };
 #define IS_AGGR_TYPE_CODE(t)   (t == RECORD_TYPE || t == UNION_TYPE)
 #define IS_AGGR_TYPE_2(TYPE1,TYPE2) \
   (TREE_CODE (TYPE1) == TREE_CODE (TYPE2)      \
-   && IS_AGGR_TYPE (TYPE1)&IS_AGGR_TYPE (TYPE2))
+   && IS_AGGR_TYPE (TYPE1) && IS_AGGR_TYPE (TYPE2))
 #define IS_OVERLOAD_TYPE(t) \
   (IS_AGGR_TYPE (t) || TREE_CODE (t) == ENUMERAL_TYPE)
 
@@ -742,68 +1162,64 @@ enum languages { lang_c, lang_cplusplus, lang_java };
    a minimum.  */
 struct lang_type
 {
-  struct
-    {
-      unsigned has_type_conversion : 1;
-      unsigned has_init_ref : 1;
-      unsigned has_default_ctor : 1;
-      unsigned uses_multiple_inheritance : 1;
-      unsigned const_needs_init : 1;
-      unsigned ref_needs_init : 1;
-      unsigned has_const_assign_ref : 1;
-      unsigned anon_aggr : 1;
-
-      unsigned has_nonpublic_ctor : 2;
-      unsigned has_nonpublic_assign_ref : 2;
-      unsigned vtable_needs_writing : 1;
-      unsigned has_assign_ref : 1;
-      unsigned gets_new : 2;
-
-      unsigned gets_delete : 2;
-      unsigned has_call_overloaded : 1;
-      unsigned has_array_ref_overloaded : 1;
-      unsigned has_arrow_overloaded : 1;
-      unsigned interface_only : 1;
-      unsigned interface_unknown : 1;
-      unsigned needs_virtual_reinit : 1;
-
-      unsigned marks: 6;
-      unsigned vec_delete_takes_size : 1;
-      unsigned declared_class : 1;
-
-      unsigned being_defined : 1;
-      unsigned redefined : 1;
-      unsigned debug_requested : 1;
-      unsigned use_template : 2;
-      unsigned got_semicolon : 1;
-      unsigned ptrmemfunc_flag : 1;
-      unsigned is_signature : 1;
-
-      unsigned is_signature_pointer : 1;
-      unsigned is_signature_reference : 1;
-      unsigned has_opaque_typedecls : 1;
-      unsigned sigtable_has_been_generated : 1;
-      unsigned was_anonymous : 1;
-      unsigned has_real_assign_ref : 1;
-      unsigned has_const_init_ref : 1;
-      unsigned has_complex_init_ref : 1;
-
-      unsigned has_complex_assign_ref : 1;
-      unsigned has_abstract_assign_ref : 1;
-      unsigned non_aggregate : 1;
-      unsigned is_partial_instantiation : 1;
-      unsigned has_mutable : 1;
-      unsigned com_interface : 1;
-      /* When adding a flag here, consider whether or not it ought to
-        apply to a template instance if it applies to the template.
-        If so, make sure to copy it in instantiate_class_template!  */
-
-      /* The MIPS compiler gets it wrong if this struct also
-        does not fill out to a multiple of 4 bytes.  Add a
-        member `dummy' with new bits if you go over the edge.  */
-      unsigned dummy : 10;
-    } type_flags;
+  unsigned char align;
 
+  unsigned has_type_conversion : 1;
+  unsigned has_init_ref : 1;
+  unsigned has_default_ctor : 1;
+  unsigned uses_multiple_inheritance : 1;
+  unsigned const_needs_init : 1;
+  unsigned ref_needs_init : 1;
+  unsigned has_const_assign_ref : 1;
+  unsigned anon_aggr : 1;
+
+  unsigned has_nonpublic_ctor : 2;
+  unsigned has_nonpublic_assign_ref : 2;
+  unsigned vtable_needs_writing : 1;
+  unsigned has_assign_ref : 1;
+  unsigned gets_new : 2;
+
+  unsigned gets_delete : 2;
+  unsigned has_call_overloaded : 1;
+  unsigned has_array_ref_overloaded : 1;
+  unsigned has_arrow_overloaded : 1;
+  unsigned interface_only : 1;
+  unsigned interface_unknown : 1;
+  unsigned needs_virtual_reinit : 1;
+
+  unsigned marks: 6;
+  unsigned vec_delete_takes_size : 1;
+  unsigned declared_class : 1;
+
+  unsigned being_defined : 1;
+  unsigned redefined : 1;
+  unsigned debug_requested : 1;
+  unsigned use_template : 2;
+  unsigned got_semicolon : 1;
+  unsigned ptrmemfunc_flag : 1;
+  unsigned was_anonymous : 1;
+
+  unsigned has_real_assign_ref : 1;
+  unsigned has_const_init_ref : 1;
+  unsigned has_complex_init_ref : 1;
+  unsigned has_complex_assign_ref : 1;
+  unsigned has_abstract_assign_ref : 1;
+  unsigned non_aggregate : 1;
+  unsigned is_partial_instantiation : 1;
+  unsigned has_mutable : 1;
+
+  unsigned com_interface : 1;
+  unsigned non_pod_class : 1;
+
+  /* When adding a flag here, consider whether or not it ought to
+     apply to a template instance if it applies to the template.  If
+     so, make sure to copy it in instantiate_class_template!  */
+
+  /* There are six bits left to fill out a 32-bit word.  Keep track of
+     this by updating the size of this bitfield whenever you add or
+     remove a flag.  */
+  unsigned dummy : 6;
+      
   int vsize;
   int vfield_parent;
 
@@ -814,9 +1230,6 @@ struct lang_type
 
   union tree_node *search_slot;
 
-  unsigned char align;
-  /* Room for another three unsigned chars.  */
-
   union tree_node *size;
 
   union tree_node *abstract_virtuals;
@@ -826,9 +1239,6 @@ struct lang_type
 
   union tree_node *methods;
 
-  union tree_node *signature;
-  union tree_node *signature_pointer_to;
-  union tree_node *signature_reference_to;
   union tree_node *template_info;
   tree befriending_classes;
 };
@@ -838,7 +1248,7 @@ struct lang_type
      1=implicit template instantiation
      2=explicit template specialization
      3=explicit template instantiation  */
-#define CLASSTYPE_USE_TEMPLATE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.use_template)
+#define CLASSTYPE_USE_TEMPLATE(NODE) (TYPE_LANG_SPECIFIC(NODE)->use_template)
 
 /* Fields used for storing information before the class is defined.
    After the class is defined, these fields hold other information.  */
@@ -848,92 +1258,53 @@ struct lang_type
 
 /* Nonzero for _CLASSTYPE means that operator new and delete are defined,
    respectively.  */
-#define TYPE_GETS_NEW(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.gets_new)
-#define TYPE_GETS_DELETE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.gets_delete)
+#define TYPE_GETS_NEW(NODE) (TYPE_LANG_SPECIFIC(NODE)->gets_new)
+#define TYPE_GETS_DELETE(NODE) (TYPE_LANG_SPECIFIC(NODE)->gets_delete)
 #define TYPE_GETS_REG_DELETE(NODE) (TYPE_GETS_DELETE (NODE) & 1)
 
 /* Nonzero for _CLASSTYPE means that operator vec delete is defined and
    takes the optional size_t argument.  */
 #define TYPE_VEC_DELETE_TAKES_SIZE(NODE) \
-  (TYPE_LANG_SPECIFIC(NODE)->type_flags.vec_delete_takes_size)
+  (TYPE_LANG_SPECIFIC(NODE)->vec_delete_takes_size)
 #define TYPE_VEC_NEW_USES_COOKIE(NODE) \
   (TYPE_NEEDS_DESTRUCTOR (NODE) \
    || (TYPE_LANG_SPECIFIC (NODE) && TYPE_VEC_DELETE_TAKES_SIZE (NODE)))
 
 /* Nonzero means that this _CLASSTYPE node defines ways of converting
    itself to other types.  */
-#define TYPE_HAS_CONVERSION(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_type_conversion)
+#define TYPE_HAS_CONVERSION(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_type_conversion)
 
 /* Nonzero means that this _CLASSTYPE node overloads operator=(X&).  */
-#define TYPE_HAS_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_assign_ref)
-#define TYPE_HAS_CONST_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_const_assign_ref)
+#define TYPE_HAS_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_assign_ref)
+#define TYPE_HAS_CONST_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_const_assign_ref)
 
 /* Nonzero means that this _CLASSTYPE node has an X(X&) constructor.  */
-#define TYPE_HAS_INIT_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_init_ref)
-#define TYPE_HAS_CONST_INIT_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_const_init_ref)
+#define TYPE_HAS_INIT_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_init_ref)
+#define TYPE_HAS_CONST_INIT_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_const_init_ref)
 
 /* Nonzero means that this type is being defined.  I.e., the left brace
    starting the definition of this type has been seen.  */
-#define TYPE_BEING_DEFINED(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.being_defined)
+#define TYPE_BEING_DEFINED(NODE) (TYPE_LANG_SPECIFIC(NODE)->being_defined)
 /* Nonzero means that this type has been redefined.  In this case, if
    convenient, don't reprocess any methods that appear in its redefinition.  */
-#define TYPE_REDEFINED(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.redefined)
-
-/* Nonzero means that this type is a signature.  */
-# define IS_SIGNATURE(NODE) (TYPE_LANG_SPECIFIC(NODE)?TYPE_LANG_SPECIFIC(NODE)->type_flags.is_signature:0)
-# define SET_SIGNATURE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.is_signature=1)
-# define CLEAR_SIGNATURE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.is_signature=0)
-
-/* Nonzero means that this type is a signature pointer type.  */
-# define IS_SIGNATURE_POINTER(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.is_signature_pointer)
-
-/* Nonzero means that this type is a signature reference type.  */
-# define IS_SIGNATURE_REFERENCE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.is_signature_reference)
-
-/* Nonzero means that this signature contains opaque type declarations.  */
-#define SIGNATURE_HAS_OPAQUE_TYPEDECLS(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_opaque_typedecls)
-
-/* Nonzero means that a signature table has been generated
-   for this signature.  */
-#define SIGTABLE_HAS_BEEN_GENERATED(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.sigtable_has_been_generated)
-
-/* If NODE is a class, this is the signature type that contains NODE's
-   signature after it has been computed using sigof().  */
-#define CLASSTYPE_SIGNATURE(NODE) (TYPE_LANG_SPECIFIC(NODE)->signature)
-
-/* If NODE is a signature pointer or signature reference, this is the
-   signature type the pointer/reference points to.  */
-#define SIGNATURE_TYPE(NODE) (TYPE_LANG_SPECIFIC(NODE)->signature)
-
-/* If NODE is a signature, this is a vector of all methods defined
-   in the signature or in its base types together with their default
-   implementations.  */
-#define SIGNATURE_METHOD_VEC(NODE) (TYPE_LANG_SPECIFIC(NODE)->signature)
-
-/* If NODE is a signature, this is the _TYPE node that contains NODE's
-   signature pointer type.  */
-#define SIGNATURE_POINTER_TO(NODE) (TYPE_LANG_SPECIFIC(NODE)->signature_pointer_to)
-
-/* If NODE is a signature, this is the _TYPE node that contains NODE's
-   signature reference type.  */
-#define SIGNATURE_REFERENCE_TO(NODE) (TYPE_LANG_SPECIFIC(NODE)->signature_reference_to)
+#define TYPE_REDEFINED(NODE) (TYPE_LANG_SPECIFIC(NODE)->redefined)
 
 /* The is the basetype that contains NODE's rtti.  */
 #define CLASSTYPE_RTTI(NODE) (TYPE_LANG_SPECIFIC(NODE)->rtti)
 
 /* Nonzero means that this _CLASSTYPE node overloads operator().  */
-#define TYPE_OVERLOADS_CALL_EXPR(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_call_overloaded)
+#define TYPE_OVERLOADS_CALL_EXPR(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_call_overloaded)
 
 /* Nonzero means that this _CLASSTYPE node overloads operator[].  */
-#define TYPE_OVERLOADS_ARRAY_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_array_ref_overloaded)
+#define TYPE_OVERLOADS_ARRAY_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_array_ref_overloaded)
 
 /* Nonzero means that this _CLASSTYPE node overloads operator->.  */
-#define TYPE_OVERLOADS_ARROW(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_arrow_overloaded)
+#define TYPE_OVERLOADS_ARROW(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_arrow_overloaded)
 
 /* Nonzero means that this _CLASSTYPE (or one of its ancestors) uses
    multiple inheritance.  If this is 0 for the root of a type
    hierarchy, then we can use more efficient search techniques.  */
-#define TYPE_USES_MULTIPLE_INHERITANCE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.uses_multiple_inheritance)
+#define TYPE_USES_MULTIPLE_INHERITANCE(NODE) (TYPE_LANG_SPECIFIC(NODE)->uses_multiple_inheritance)
 
 /* Nonzero means that this _CLASSTYPE (or one of its ancestors) uses
    virtual base classes.  If this is 0 for the root of a type
@@ -960,19 +1331,19 @@ struct lang_type
 
 /* Get the value of the Nth mark bit.  */
 #define CLASSTYPE_MARKED_N(NODE, N)                                    \
-  (((CLASS_TYPE_P (NODE) ? TYPE_LANG_SPECIFIC (NODE)->type_flags.marks \
+  (((CLASS_TYPE_P (NODE) ? TYPE_LANG_SPECIFIC (NODE)->marks    \
      : TYPE_ALIAS_SET (NODE)) & (1 << N)) != 0)
 
 /* Set the Nth mark bit.  */
 #define SET_CLASSTYPE_MARKED_N(NODE, N)                                        \
   (CLASS_TYPE_P (NODE)                                                 \
-   ? (TYPE_LANG_SPECIFIC (NODE)->type_flags.marks |= (1 << (N)))       \
+   ? (TYPE_LANG_SPECIFIC (NODE)->marks |= (1 << (N)))  \
    : (TYPE_ALIAS_SET (NODE) |= (1 << (N))))
 
 /* Clear the Nth mark bit.  */
 #define CLEAR_CLASSTYPE_MARKED_N(NODE, N)                              \
   (CLASS_TYPE_P (NODE)                                                 \
-   ? (TYPE_LANG_SPECIFIC (NODE)->type_flags.marks &= ~(1 << (N)))      \
+   ? (TYPE_LANG_SPECIFIC (NODE)->marks &= ~(1 << (N))) \
    : (TYPE_ALIAS_SET (NODE) &= ~(1 << (N))))
 
 /* Get the value of the mark bits.  */
@@ -1010,9 +1381,6 @@ struct lang_type
    1, if D's vtable came from B2.  */
 #define CLASSTYPE_VFIELD_PARENT(NODE)  (TYPE_LANG_SPECIFIC(NODE)->vfield_parent)
 
-/* Remove when done merging.  */
-#define CLASSTYPE_VFIELD(NODE) TYPE_VFIELD(NODE)
-
 /* The number of virtual functions defined for this
    _CLASSTYPE node.  */
 #define CLASSTYPE_VSIZE(NODE) (TYPE_LANG_SPECIFIC(NODE)->vsize)
@@ -1041,36 +1409,39 @@ struct lang_type
 #define CLASSTYPE_ABSTRACT_VIRTUALS(NODE) (TYPE_LANG_SPECIFIC(NODE)->abstract_virtuals)
 
 /* Nonzero means that this aggr type has been `closed' by a semicolon.  */
-#define CLASSTYPE_GOT_SEMICOLON(NODE) (TYPE_LANG_SPECIFIC (NODE)->type_flags.got_semicolon)
+#define CLASSTYPE_GOT_SEMICOLON(NODE) (TYPE_LANG_SPECIFIC (NODE)->got_semicolon)
 
 /* Nonzero means that the main virtual function table pointer needs to be
    set because base constructors have placed the wrong value there.
    If this is zero, it means that they placed the right value there,
    and there is no need to change it.  */
-#define CLASSTYPE_NEEDS_VIRTUAL_REINIT(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.needs_virtual_reinit)
+#define CLASSTYPE_NEEDS_VIRTUAL_REINIT(NODE) (TYPE_LANG_SPECIFIC(NODE)->needs_virtual_reinit)
 
 /* Nonzero means that if this type has virtual functions, that
    the virtual function table will be written out.  */
-#define CLASSTYPE_VTABLE_NEEDS_WRITING(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.vtable_needs_writing)
+#define CLASSTYPE_VTABLE_NEEDS_WRITING(NODE) (TYPE_LANG_SPECIFIC(NODE)->vtable_needs_writing)
 
 /* Nonzero means that this type has an X() constructor.  */
-#define TYPE_HAS_DEFAULT_CONSTRUCTOR(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_default_ctor)
+#define TYPE_HAS_DEFAULT_CONSTRUCTOR(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_default_ctor)
 
 /* Nonzero means the type declared a ctor as private or protected.  We
    use this to make sure we don't try to generate a copy ctor for a 
    class that has a member of type NODE.  */
-#define TYPE_HAS_NONPUBLIC_CTOR(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_nonpublic_ctor)
+#define TYPE_HAS_NONPUBLIC_CTOR(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_nonpublic_ctor)
 
 /* Ditto, for operator=.  */
-#define TYPE_HAS_NONPUBLIC_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_nonpublic_assign_ref)
+#define TYPE_HAS_NONPUBLIC_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_nonpublic_assign_ref)
 
 /* Nonzero means that this type contains a mutable member */
-#define CLASSTYPE_HAS_MUTABLE(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_mutable)
+#define CLASSTYPE_HAS_MUTABLE(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_mutable)
 #define TYPE_HAS_MUTABLE_P(NODE) (cp_has_mutable_p (NODE))
 
+/*  Nonzero means that this class type is a non-POD class.  */
+#define CLASSTYPE_NON_POD_P(NODE) (TYPE_LANG_SPECIFIC (NODE)->non_pod_class)
+
 /* Nonzero means that this type is meant for communication via COM.  */
 #define CLASSTYPE_COM_INTERFACE(NODE) \
-  (TYPE_LANG_SPECIFIC(NODE)->type_flags.com_interface)
+  (TYPE_LANG_SPECIFIC(NODE)->com_interface)
 
 /* A list of class types of which this type is a friend.  The
    TREE_VALUE is normally a TYPE, but will be a TEMPLATE_DECL in the
@@ -1082,27 +1453,27 @@ struct lang_type
   (TYPE_LANG_SPECIFIC (NODE)->befriending_classes)
 
 /* Say whether this node was declared as a "class" or a "struct".  */
-#define CLASSTYPE_DECLARED_CLASS(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.declared_class)
+#define CLASSTYPE_DECLARED_CLASS(NODE) (TYPE_LANG_SPECIFIC(NODE)->declared_class)
 
 /* Nonzero if this class has const members which have no specified initialization.  */
-#define CLASSTYPE_READONLY_FIELDS_NEED_INIT(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.const_needs_init)
+#define CLASSTYPE_READONLY_FIELDS_NEED_INIT(NODE) (TYPE_LANG_SPECIFIC(NODE)->const_needs_init)
 
 /* Nonzero if this class has ref members which have no specified initialization.  */
-#define CLASSTYPE_REF_FIELDS_NEED_INIT(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.ref_needs_init)
+#define CLASSTYPE_REF_FIELDS_NEED_INIT(NODE) (TYPE_LANG_SPECIFIC(NODE)->ref_needs_init)
 
 /* Nonzero if this class is included from a header file which employs
    `#pragma interface', and it is not included in its implementation file.  */
-#define CLASSTYPE_INTERFACE_ONLY(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.interface_only)
+#define CLASSTYPE_INTERFACE_ONLY(NODE) (TYPE_LANG_SPECIFIC(NODE)->interface_only)
 
 /* Same as above, but for classes whose purpose we do not know.  */
-#define CLASSTYPE_INTERFACE_UNKNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.interface_unknown)
-#define CLASSTYPE_INTERFACE_KNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.interface_unknown == 0)
-#define SET_CLASSTYPE_INTERFACE_UNKNOWN_X(NODE,X) (TYPE_LANG_SPECIFIC(NODE)->type_flags.interface_unknown = !!(X))
-#define SET_CLASSTYPE_INTERFACE_UNKNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.interface_unknown = 1)
-#define SET_CLASSTYPE_INTERFACE_KNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.interface_unknown = 0)
+#define CLASSTYPE_INTERFACE_UNKNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->interface_unknown)
+#define CLASSTYPE_INTERFACE_KNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->interface_unknown == 0)
+#define SET_CLASSTYPE_INTERFACE_UNKNOWN_X(NODE,X) (TYPE_LANG_SPECIFIC(NODE)->interface_unknown = !!(X))
+#define SET_CLASSTYPE_INTERFACE_UNKNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->interface_unknown = 1)
+#define SET_CLASSTYPE_INTERFACE_KNOWN(NODE) (TYPE_LANG_SPECIFIC(NODE)->interface_unknown = 0)
 
 /* Nonzero if a _DECL node requires us to output debug info for this class.  */
-#define CLASSTYPE_DEBUG_REQUESTED(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.debug_requested)
+#define CLASSTYPE_DEBUG_REQUESTED(NODE) (TYPE_LANG_SPECIFIC(NODE)->debug_requested)
 \f
 /* Additional macros for inheritance information.  */
 
@@ -1117,7 +1488,7 @@ struct lang_type
 
    We use TREE_VIA_PROTECTED and TREE_VIA_PUBLIC, but private
    inheritance is indicated by the absence of the other two flags, not
-   by TREE_VIAR_PRIVATE, which is unused.
+   by TREE_VIA_PRIVATE, which is unused.
 
    The TREE_CHAIN is for scratch space in search.c.  */
 
@@ -1196,12 +1567,14 @@ struct lang_type
 \f
 
 /* If a DECL has DECL_LANG_SPECIFIC, it is either a lang_decl_flags or
-   a lang_decl (which has lang_decl_flags as its initial prefix).  A
-   FUNCTION_DECL, NAMESPACE_DECL, TYPE_DECL, or USING_DECL may have a
-   full lang_decl.  A FIELD_DECL, or a static data member VAR_DECL,
-   will have only lang_decl_flags.  Thus, one should only access the
-   members of lang_decl that are not in lang_decl_flags for DECLs that
-   are not FIELD_DECLs or VAR_DECLs.  */
+   a lang_decl (which has lang_decl_flags as its initial prefix).
+   This macro is nonzero for tree nodes whose DECL_LANG_SPECIFIC is
+   the full lang_decl, and not just lang_decl_flags.  */
+#define CAN_HAVE_FULL_LANG_DECL_P(NODE)                \
+  (!(TREE_CODE ((NODE)) == VAR_DECL            \
+     || TREE_CODE ((NODE)) == CONST_DECL       \
+     || TREE_CODE ((NODE)) == FIELD_DECL       \
+     || TREE_CODE ((NODE)) == USING_DECL))
 
 struct lang_decl_flags
 {
@@ -1217,38 +1590,43 @@ struct lang_decl_flags
   unsigned static_function : 1;
   unsigned const_memfunc : 1;
   unsigned volatile_memfunc : 1;
-
   unsigned abstract_virtual : 1;
-  unsigned permanent_attr : 1 ;
   unsigned constructor_for_vbase_attr : 1;
+
   unsigned mutable_flag : 1;
-  unsigned is_default_implementation : 1;
   unsigned saved_inline : 1;
   unsigned use_template : 2;
-
   unsigned nonconverting : 1;
   unsigned declared_inline : 1;
   unsigned not_really_extern : 1;
   unsigned needs_final_overrider : 1;
+
   unsigned bitfield : 1;
   unsigned defined_in_class : 1;
-  unsigned dummy : 4;
+  unsigned pending_inline_p : 1;
+  unsigned global_ctor_p : 1;
+  unsigned global_dtor_p : 1;
+  unsigned dummy : 3;
 
-  tree access;
   tree context;
 
-  /* In a template FUNCTION_DECL, this is DECL_SAVED_TREE.
-     In a non-template FUNCTION_DECL, this is DECL_MEMFUNC_POINTER_TO.
-     In a FIELD_DECL, this is DECL_MEMFUNC_POINTING_TO.  */
-  tree memfunc_pointer_to;
-
   union {
-    /* In a FUNCTION_DECL, this is DECL_TEMPLATE_INFO.  */
+    /* In a FUNCTION_DECL, VAR_DECL, TYPE_DECL, or TEMPLATE_DECL, this
+       is DECL_TEMPLATE_INFO.  */
     tree template_info;
 
     /* In a NAMESPACE_DECL, this is NAMESPACE_LEVEL.  */
     struct binding_level *level;
   } u;
+
+  union {
+    /* This is DECL_ACCESS.  */
+    tree access;
+
+    /* In a namespace-scope FUNCTION_DECL, this is
+       GLOBAL_INIT_PRIORITY.  */
+    int init_priority;
+  } u2;
 };
 
 struct lang_decl
@@ -1257,10 +1635,15 @@ struct lang_decl
 
   tree main_decl_variant;
   tree befriending_classes;
+
+  /* In a FUNCTION_DECL, this is DECL_SAVED_TREE.  */
+  tree saved_tree;
+
   union
   {
     tree sorted_fields;
     struct pending_inline *pending_inline_info;
+    struct language_function *saved_language_function;
   } u;
 };
 
@@ -1289,9 +1672,14 @@ struct lang_decl
   (DESTRUCTOR_NAME_P (DECL_ASSEMBLER_NAME (NODE))      \
    && DECL_LANGUAGE (NODE) == lang_cplusplus)
 
+/* Non-zero if NODE is a user-defined conversion operator.  */
 #define DECL_CONV_FN_P(NODE)                                                \
   (IDENTIFIER_TYPENAME_P (DECL_NAME (NODE)) && TREE_TYPE (DECL_NAME (NODE)))
 
+/* Non-zero if NODE is an overloaded operator.  */
+#define DECL_OVERLOADED_OPERATOR_P(NODE)       \
+  (IDENTIFIER_OPNAME_P (DECL_NAME ((NODE))))
+
 /* For FUNCTION_DECLs: nonzero means that this function is a constructor
    for an object with virtual baseclasses.  */
 #define DECL_CONSTRUCTOR_FOR_VBASE_P(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.constructor_for_vbase_attr)
@@ -1306,10 +1694,6 @@ struct lang_decl
 #define SET_DECL_TINFO_FN_P(NODE) \
   (DECL_LANG_SPECIFIC((NODE))->decl_flags.mutable_flag = 1)
 
-/* For FUNCTION_DECLs: nonzero means that this function is a default
-   implementation of a signature method.  */
-#define IS_DEFAULT_IMPLEMENTATION(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.is_default_implementation)
-
 /* Nonzero for _DECL means that this decl appears in (or will appear
    in) as a member in a RECORD_TYPE or UNION_TYPE node.  It is also for
    detecting circularity in case members are multiply defined.  In the
@@ -1381,9 +1765,6 @@ struct lang_decl
    must be overridden by derived classes.  */
 #define DECL_NEEDS_FINAL_OVERRIDER_P(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.needs_final_overrider)
 
-/* Nonzero if allocated on permanent_obstack.  */
-#define LANG_DECL_PERMANENT(LANGDECL) ((LANGDECL)->decl_flags.permanent_attr)
-
 /* The _TYPE context in which this _DECL appears.  This field holds the
    class where a virtual function instance is actually defined, and the
    lexical scope of a friend function defined in a class body. */
@@ -1397,10 +1778,14 @@ struct lang_decl
   (DECL_CONTEXT (NODE) ? DECL_CONTEXT (NODE) : global_namespace)
 #define FROB_CONTEXT(NODE)   ((NODE) == global_namespace ? NULL_TREE : (NODE))
 
+/* For a virtual function, the base where we find its vtable entry.
+   For a non-virtual function, the base where it is defined.  */
+#define DECL_VIRTUAL_CONTEXT(NODE) DECL_CONTEXT (NODE)
+
 /* 1 iff NODE has namespace scope, including the global namespace.  */
-#define DECL_NAMESPACE_SCOPE_P(NODE) \
-  (DECL_CONTEXT (NODE) == NULL_TREE \
-   || TREE_CODE (DECL_CONTEXT (NODE)) == NAMESPACE_DECL)
+#define DECL_NAMESPACE_SCOPE_P(NODE)                           \
+  (!DECL_TEMPLATE_PARM_P (NODE)                                        \
+   && TREE_CODE (CP_DECL_CONTEXT (NODE)) == NAMESPACE_DECL)
 
 /* 1 iff NODE is a class member.  */
 #define DECL_CLASS_SCOPE_P(NODE) \
@@ -1415,68 +1800,69 @@ struct lang_decl
 /* For a NAMESPACE_DECL: the list of using namespace directives
    The PURPOSE is the used namespace, the value is the namespace
    that is the common ancestor. */
-#define DECL_NAMESPACE_USING(NODE) DECL_VINDEX(NODE)
+#define DECL_NAMESPACE_USING(NODE) DECL_VINDEX (NAMESPACE_DECL_CHECK (NODE))
 
 /* In a NAMESPACE_DECL, the DECL_INITIAL is used to record all users
    of a namespace, to record the transitive closure of using namespace. */
-#define DECL_NAMESPACE_USERS(NODE) DECL_INITIAL (NODE)
+#define DECL_NAMESPACE_USERS(NODE) DECL_INITIAL (NAMESPACE_DECL_CHECK (NODE))
 
 /* In a NAMESPACE_DECL, points to the original namespace if this is
    a namespace alias.  */
-#define DECL_NAMESPACE_ALIAS(NODE) DECL_ABSTRACT_ORIGIN (NODE)
+#define DECL_NAMESPACE_ALIAS(NODE) \
+       DECL_ABSTRACT_ORIGIN (NAMESPACE_DECL_CHECK (NODE))
 #define ORIGINAL_NAMESPACE(NODE)  \
   (DECL_NAMESPACE_ALIAS (NODE) ? DECL_NAMESPACE_ALIAS (NODE) : (NODE))
 
 /* In a non-local VAR_DECL with static storage duration, this is the
    initialization priority.  If this value is zero, the NODE will be
    initialized at the DEFAULT_INIT_PRIORITY.  */
-#define DECL_INIT_PRIORITY(NODE) (DECL_FIELD_SIZE ((NODE)))
+#define DECL_INIT_PRIORITY(NODE) (DECL_FIELD_SIZE (VAR_DECL_CHECK (NODE)))
 
 /* In a TREE_LIST concatenating using directives, indicate indirekt
    directives  */
-#define TREE_INDIRECT_USING(NODE) ((NODE)->common.lang_flag_0)
+#define TREE_INDIRECT_USING(NODE) (TREE_LIST_CHECK (NODE)->common.lang_flag_0)
 
 /* In a VAR_DECL for a variable declared in a for statement,
    this is the shadowed (local) variable.  */
-#define DECL_SHADOWED_FOR_VAR(NODE) DECL_RESULT(NODE)
+#define DECL_SHADOWED_FOR_VAR(NODE) DECL_RESULT(VAR_DECL_CHECK (NODE))
 
 /* Points back to the decl which caused this lang_decl to be allocated.  */
 #define DECL_MAIN_VARIANT(NODE) (DECL_LANG_SPECIFIC(NODE)->main_decl_variant)
 
-/* For a FUNCTION_DECL: if this function was declared inline inside of
-   a class declaration, this is where the text for the function is
-   squirreled away.  */
-#define DECL_PENDING_INLINE_INFO(NODE) (DECL_LANG_SPECIFIC(NODE)->u.pending_inline_info)
+/* In a FUNCTION_DECL, this is nonzero if this function was defined in
+   the class definition.  We have saved away the text of the function,
+   but have not yet processed it.  */
+#define DECL_PENDING_INLINE_P(NODE) \
+  (DECL_LANG_SPECIFIC (FUNCTION_DECL_CHECK (NODE))->decl_flags.pending_inline_p)
+   
+/* If DECL_PENDING_INLINE_P holds, this is the saved text of the
+   function.  */
+#define DECL_PENDING_INLINE_INFO(NODE) \
+  (DECL_LANG_SPECIFIC(NODE)->u.pending_inline_info)
 
 /* For a TYPE_DECL: if this function has many fields, we'll sort them
    and put them into a TREE_VEC. */
-#define DECL_SORTED_FIELDS(NODE) (DECL_LANG_SPECIFIC(NODE)->u.sorted_fields)
+#define DECL_SORTED_FIELDS(NODE) \
+       (DECL_LANG_SPECIFIC (TYPE_DECL_CHECK (NODE))->u.sorted_fields)
 
 /* True if on the saved_inlines (see decl2.c) list.  */
 #define DECL_SAVED_INLINE(DECL) \
   (DECL_LANG_SPECIFIC(DECL)->decl_flags.saved_inline)
 
-/* For a FUNCTION_DECL: if this function was declared inside a signature
-   declaration, this is the corresponding member function pointer that was
-   created for it.  */
-#define DECL_MEMFUNC_POINTER_TO(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.memfunc_pointer_to)
-
-/* For a FIELD_DECL: this points to the signature member function from
-   which this signature member function pointer was created.  */
-#define DECL_MEMFUNC_POINTING_TO(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.memfunc_pointer_to)
-
-/* For a VAR_DECL or FUNCTION_DECL: template-specific information.  */
+/* For a VAR_DECL, FUNCTION_DECL, TYPE_DECL or TEMPLATE_DECL:
+   template-specific information.  */
 #define DECL_TEMPLATE_INFO(NODE) \
-  (DECL_LANG_SPECIFIC(NODE)->decl_flags.u.template_info)
+  (DECL_LANG_SPECIFIC(VAR_TEMPL_TYPE_OR_FUNCTION_DECL_CHECK (NODE))->decl_flags.u.template_info)
 
 /* Template information for a RECORD_TYPE or UNION_TYPE.  */
-#define CLASSTYPE_TEMPLATE_INFO(NODE) (TYPE_LANG_SPECIFIC(NODE)->template_info)
+#define CLASSTYPE_TEMPLATE_INFO(NODE) \
+  (TYPE_LANG_SPECIFIC(RECORD_OR_UNION_TYPE_CHECK (NODE))->template_info)
 
 /* Template information for an ENUMERAL_TYPE.  Although an enumeration may
    not be a primary template, it may be declared within the scope of a
    primary template and the enumeration constants may depend on
    non-type template parameters.  */
-#define ENUM_TEMPLATE_INFO(NODE) (TYPE_BINFO (NODE))
+#define ENUM_TEMPLATE_INFO(NODE) (TYPE_BINFO (ENUMERAL_TYPE_CHECK (NODE)))
 
 /* Template information for a template template parameter.  */
 #define TEMPLATE_TEMPLATE_PARM_TEMPLATE_INFO(NODE) (TYPE_BINFO (NODE))
@@ -1501,6 +1887,66 @@ struct lang_decl
 #define TI_SPEC_INFO(NODE) (TREE_CHAIN (NODE))
 #define TI_PENDING_TEMPLATE_FLAG(NODE) TREE_LANG_FLAG_1 (NODE)
 
+/* We use TREE_VECs to hold template arguments.  If there is only one
+   level of template arguments, then the TREE_VEC contains the
+   arguments directly.  If there is more than one level of template
+   arguments, then each entry in the TREE_VEC is itself a TREE_VEC,
+   containing the template arguments for a single level.  The first
+   entry in the outer TREE_VEC is the outermost level of template
+   parameters; the last is the innermost.  
+
+   It is incorrect to ever form a template argument vector containing
+   only one level of arguments, but which is a TREE_VEC containing as
+   its only entry the TREE_VEC for that level.  */
+
+/* Non-zero if the template arguments is actually a vector of vectors,
+   rather than just a vector.  */
+#define TMPL_ARGS_HAVE_MULTIPLE_LEVELS(NODE) \
+  (NODE != NULL_TREE                                           \
+   && TREE_CODE (NODE) == TREE_VEC                             \
+   && TREE_VEC_LENGTH (NODE) > 0                               \
+   && TREE_VEC_ELT (NODE, 0) != NULL_TREE                      \
+   && TREE_CODE (TREE_VEC_ELT (NODE, 0)) == TREE_VEC)
+
+/* The depth of a template argument vector.  When called directly by
+   the parser, we use a TREE_LIST rather than a TREE_VEC to represent
+   template arguments.  In fact, we may even see NULL_TREE if there
+   are no template arguments.  In both of those cases, there is only
+   one level of template arguments.  */
+#define TMPL_ARGS_DEPTH(NODE)                                  \
+  (TMPL_ARGS_HAVE_MULTIPLE_LEVELS (NODE) ? TREE_VEC_LENGTH (NODE) : 1)
+
+/* The LEVELth level of the template ARGS.  Note that template
+   parameter levels are indexed from 1, not from 0.  */
+#define TMPL_ARGS_LEVEL(ARGS, LEVEL)           \
+  (TMPL_ARGS_HAVE_MULTIPLE_LEVELS (ARGS)       \
+   ? TREE_VEC_ELT ((ARGS), (LEVEL) - 1) : ARGS)
+
+/* Set the LEVELth level of the template ARGS to VAL.  This macro does
+   not work with single-level argument vectors.  */
+#define SET_TMPL_ARGS_LEVEL(ARGS, LEVEL, VAL)  \
+  (TREE_VEC_ELT ((ARGS), (LEVEL) - 1) = (VAL))
+
+/* Accesses the IDXth parameter in the LEVELth level of the ARGS.  */
+#define TMPL_ARG(ARGS, LEVEL, IDX)                             \
+  (TREE_VEC_ELT (TMPL_ARGS_LEVEL (ARGS, LEVEL), IDX))
+
+/* Set the IDXth element in the LEVELth level of ARGS to VAL.  This
+   macro does not work with single-level argument vectors.  */
+#define SET_TMPL_ARG(ARGS, LEVEL, IDX, VAL)                    \
+  (TREE_VEC_ELT (TREE_VEC_ELT ((ARGS), (LEVEL) - 1), (IDX)) = (VAL))
+
+/* Given a single level of template arguments in NODE, return the
+   number of arguments.  */
+#define NUM_TMPL_ARGS(NODE)                            \
+  ((NODE) == NULL_TREE ? 0                             \
+   : (TREE_CODE (NODE) == TREE_VEC                     \
+      ? TREE_VEC_LENGTH (NODE) : list_length (NODE)))
+
+/* The number of levels of template parameters given by NODE.  */
+#define TMPL_PARMS_DEPTH(NODE) \
+  (TREE_INT_CST_HIGH (TREE_PURPOSE (NODE)))
+
 /* The TEMPLATE_DECL instantiated or specialized by NODE.  This
    TEMPLATE_DECL will be the immediate parent, not the most general
    template.  For example, in:
@@ -1539,7 +1985,7 @@ struct lang_decl
 #define TYPE_TI_TEMPLATE(NODE)                 \
   (TI_TEMPLATE (TYPE_TEMPLATE_INFO (NODE)))
 
-/* Like DECL_TI_ARGS, but for an ENUMERAL_, RECORD_, or UNION_TYPE.  */
+/* Like DECL_TI_ARGS, but for an ENUMERAL_, RECORD_, or UNION_TYPE.  */
 #define TYPE_TI_ARGS(NODE)                     \
   (TI_ARGS (TYPE_TEMPLATE_INFO (NODE)))
 
@@ -1550,9 +1996,15 @@ struct lang_decl
    the class definition is complete.  */
 #define TEMPLATE_PARMS_FOR_INLINE(NODE) TREE_LANG_FLAG_1 (NODE)
 
-/* In a template FUNCTION_DECL, the tree structure that will be
-   substituted into to obtain instantiations.  */
-#define DECL_SAVED_TREE(NODE)          DECL_MEMFUNC_POINTER_TO (NODE)
+/* In a FUNCTION_DECL, the saved representation of the body of the
+   entire function.  Usually a COMPOUND_STMT, but this may also be a
+   RETURN_INIT, CTOR_INITIALIZER, or TRY_BLOCK.  */
+#define DECL_SAVED_TREE(NODE) \
+  (DECL_LANG_SPECIFIC (FUNCTION_DECL_CHECK (NODE))->saved_tree)
+
+/* In a FUNCTION_DECL, the saved language-specific per-function data.  */
+#define DECL_SAVED_FUNCTION_DATA(NODE) \
+  (DECL_LANG_SPECIFIC (FUNCTION_DECL_CHECK (NODE))->u.saved_language_function)
 
 #define COMPOUND_STMT_NO_SCOPE(NODE)   TREE_LANG_FLAG_0 (NODE)
 #define NEW_EXPR_USE_GLOBAL(NODE)      TREE_LANG_FLAG_0 (NODE)
@@ -1560,6 +2012,14 @@ struct lang_decl
 #define DELETE_EXPR_USE_VEC(NODE)      TREE_LANG_FLAG_1 (NODE)
 #define LOOKUP_EXPR_GLOBAL(NODE)       TREE_LANG_FLAG_0 (NODE)
 
+/* Nonzero if this AGGR_INIT_EXPR provides for initialization via a
+   constructor call, rather than an ordinary function call.  */
+#define AGGR_INIT_VIA_CTOR_P(NODE) \
+  TREE_LANG_FLAG_0 (AGGR_INIT_EXPR_CHECK (NODE))
+
+/* Nonzero if this statement should be considered a full-expression.  */
+#define STMT_IS_FULL_EXPR_P(NODE) TREE_LANG_FLAG_1 ((NODE))
+
 /* The TYPE_MAIN_DECL for a class template type is a TYPE_DECL, not a
    TEMPLATE_DECL.  This macro determines whether or not a given class
    type is really a template type, as opposed to an instantiation or
@@ -1588,7 +2048,7 @@ struct lang_decl
 
 /* Nonzero in INTEGER_CST means that this int is negative by dint of
    using a twos-complement negated operand.  */
-#define TREE_NEGATED_INT(NODE) (TREE_LANG_FLAG_0 (NODE))
+#define TREE_NEGATED_INT(NODE) TREE_LANG_FLAG_0 (INTEGER_CST_CHECK (NODE))
 
 #if 0                          /* UNUSED */
 /* Nonzero in any kind of _EXPR or _REF node means that it is a call
@@ -1629,11 +2089,11 @@ extern int flag_new_for_scope;
 
 /* This flag is true of a local VAR_DECL if it was declared in a for
    statement, but we are no longer in the scope of the for.  */
-#define DECL_DEAD_FOR_LOCAL(NODE) DECL_LANG_FLAG_7 (NODE)
+#define DECL_DEAD_FOR_LOCAL(NODE) DECL_LANG_FLAG_7 (VAR_DECL_CHECK (NODE))
 
 /* This flag is set on a VAR_DECL that is a DECL_DEAD_FOR_LOCAL
    if we already emitted a warning about using it.  */
-#define DECL_ERROR_REPORTED(NODE) DECL_LANG_FLAG_0 (NODE)
+#define DECL_ERROR_REPORTED(NODE) DECL_LANG_FLAG_0 (VAR_DECL_CHECK (NODE))
 
 /* This _DECL represents a compiler-generated entity.  */
 #define SET_DECL_ARTIFICIAL(NODE) (DECL_ARTIFICIAL (NODE) = 1)
@@ -1643,24 +2103,31 @@ extern int flag_new_for_scope;
 
 /* In a FIELD_DECL, nonzero if the decl was originally a bitfield.  */
 #define DECL_C_BIT_FIELD(NODE) \
-  (DECL_LANG_SPECIFIC (NODE) && DECL_LANG_SPECIFIC (NODE)->decl_flags.bitfield)
+  (DECL_LANG_SPECIFIC (FIELD_DECL_CHECK (NODE))\
+   && DECL_LANG_SPECIFIC (NODE)->decl_flags.bitfield)
 #define SET_DECL_C_BIT_FIELD(NODE) \
-  (DECL_LANG_SPECIFIC (NODE)->decl_flags.bitfield = 1)
-
-/* Nonzero if the type T promotes to itself.
-   ANSI C states explicitly the list of types that promote;
-   in particular, short promotes to int even if they have the same width.  */
-#define C_PROMOTING_INTEGER_TYPE_P(t)                          \
-  (TREE_CODE ((t)) == INTEGER_TYPE                             \
-   && (TYPE_MAIN_VARIANT (t) == char_type_node                 \
-       || TYPE_MAIN_VARIANT (t) == signed_char_type_node       \
-       || TYPE_MAIN_VARIANT (t) == unsigned_char_type_node     \
-       || TYPE_MAIN_VARIANT (t) == short_integer_type_node     \
-       || TYPE_MAIN_VARIANT (t) == short_unsigned_type_node))
+  (DECL_LANG_SPECIFIC (FIELD_DECL_CHECK (NODE))->decl_flags.bitfield = 1)
 
 #define INTEGRAL_CODE_P(CODE) \
   (CODE == INTEGER_TYPE || CODE == ENUMERAL_TYPE || CODE == BOOLEAN_TYPE)
-#define ARITHMETIC_TYPE_P(TYPE) (INTEGRAL_TYPE_P (TYPE) || FLOAT_TYPE_P (TYPE))
+
+/* [basic.fundamental]
+
+   Types  bool, char, wchar_t, and the signed and unsigned integer types
+   are collectively called integral types.  
+
+   Note that INTEGRAL_TYPE_P, as defined in tree.h, allows enumeration
+   types as well, which is incorrect in C++.  */
+#define CP_INTEGRAL_TYPE_P(TYPE)               \
+  (TREE_CODE ((TYPE)) == BOOLEAN_TYPE          \
+   || TREE_CODE ((TYPE)) == INTEGER_TYPE)
+
+/* [basic.fundamental]
+
+   Integral and floating types are collectively called arithmetic
+   types.  */
+#define ARITHMETIC_TYPE_P(TYPE) \
+  (CP_INTEGRAL_TYPE_P (TYPE) || TREE_CODE (TYPE) == REAL_TYPE)
 
 /* Mark which labels are explicitly declared.
    These may be shadowed, and may be referenced from nested functions.  */
@@ -1700,25 +2167,18 @@ extern int flag_new_for_scope;
 /* Nonzero for _TYPE means that the _TYPE defines a destructor.  */
 #define TYPE_HAS_DESTRUCTOR(NODE) (TYPE_LANG_FLAG_2(NODE))
 
-#if 0
-/* Nonzero for _TYPE node means that creating an object of this type
-   will involve a call to a constructor.  This can apply to objects
-   of ARRAY_TYPE if the type of the elements needs a constructor.  */
-#define TYPE_NEEDS_CONSTRUCTING(NODE) ... defined in ../tree.h ...
-#endif
-
 /* Nonzero means that an object of this type can not be initialized using
    an initializer list.  */
 #define CLASSTYPE_NON_AGGREGATE(NODE) \
-  (TYPE_LANG_SPECIFIC (NODE)->type_flags.non_aggregate)
+  (TYPE_LANG_SPECIFIC (NODE)->non_aggregate)
 #define TYPE_NON_AGGREGATE_CLASS(NODE) \
   (IS_AGGR_TYPE (NODE) && CLASSTYPE_NON_AGGREGATE (NODE))
 
 /* Nonzero if there is a user-defined X::op=(x&) for this class.  */
-#define TYPE_HAS_REAL_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_real_assign_ref)
-#define TYPE_HAS_COMPLEX_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_complex_assign_ref)
-#define TYPE_HAS_ABSTRACT_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_abstract_assign_ref)
-#define TYPE_HAS_COMPLEX_INIT_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->type_flags.has_complex_init_ref)
+#define TYPE_HAS_REAL_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_real_assign_ref)
+#define TYPE_HAS_COMPLEX_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_complex_assign_ref)
+#define TYPE_HAS_ABSTRACT_ASSIGN_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_abstract_assign_ref)
+#define TYPE_HAS_COMPLEX_INIT_REF(NODE) (TYPE_LANG_SPECIFIC(NODE)->has_complex_init_ref)
 
 /* Nonzero for _TYPE node means that destroying an object of this type
    will involve a call to a destructor.  This can apply to objects
@@ -1752,10 +2212,13 @@ extern int flag_new_for_scope;
 
 /* Nonzero for _TYPE node means that this type is a pointer to member
    function type.  */
-#define TYPE_PTRMEMFUNC_P(NODE) \
-  (TREE_CODE(NODE) == RECORD_TYPE && TYPE_PTRMEMFUNC_FLAG (NODE))
+#define TYPE_PTRMEMFUNC_P(NODE)                \
+  (TREE_CODE(NODE) == RECORD_TYPE      \
+   && TYPE_LANG_SPECIFIC(NODE)         \
+   && TYPE_PTRMEMFUNC_FLAG (NODE))
+
 #define TYPE_PTRMEMFUNC_FLAG(NODE) \
-  (TYPE_LANG_SPECIFIC(NODE)->type_flags.ptrmemfunc_flag)
+  (TYPE_LANG_SPECIFIC(NODE)->ptrmemfunc_flag)
 
 /* A pointer-to-function member type looks like:
 
@@ -1826,36 +2289,57 @@ extern int flag_new_for_scope;
 #define DELTA2_FROM_PTRMEMFUNC(NODE) delta2_from_ptrmemfunc ((NODE))
 #define PFN_FROM_PTRMEMFUNC(NODE) pfn_from_ptrmemfunc ((NODE))
 
+/* For a pointer-to-member type of the form `T X::*', this is `X'.  */
+#define TYPE_PTRMEM_CLASS_TYPE(NODE)                   \
+  (TYPE_PTRMEM_P ((NODE))                              \
+   ? TYPE_OFFSET_BASETYPE (TREE_TYPE ((NODE)))         \
+   : TYPE_PTRMEMFUNC_OBJECT_TYPE ((NODE)))
+
+/* For a pointer-to-member type of the form `T X::*', this is `T'.  */
+#define TYPE_PTRMEM_POINTED_TO_TYPE(NODE)              \
+   (TYPE_PTRMEM_P ((NODE))                             \
+    ? TREE_TYPE (TREE_TYPE (NODE))                     \
+    : TREE_TYPE (TYPE_PTRMEMFUNC_FN_TYPE ((NODE))))
+
 /* For a pointer-to-member constant `X::Y' this is the RECORD_TYPE for
    `X'.  */
-#define PTRMEM_CST_CLASS(NODE)                           \
-   (TYPE_PTRMEM_P (TREE_TYPE (NODE))                     \
-    ? TYPE_OFFSET_BASETYPE (TREE_TYPE (TREE_TYPE (NODE))) \
-    : TYPE_PTRMEMFUNC_OBJECT_TYPE (TREE_TYPE (NODE)))
+#define PTRMEM_CST_CLASS(NODE) \
+  TYPE_PTRMEM_CLASS_TYPE (TREE_TYPE (PTRMEM_CST_CHECK (NODE)))
 
 /* For a pointer-to-member constant `X::Y' this is the _DECL for 
    `Y'.  */
-#define PTRMEM_CST_MEMBER(NODE) (((ptrmem_cst_t) NODE)->member)
+#define PTRMEM_CST_MEMBER(NODE) (((ptrmem_cst_t)PTRMEM_CST_CHECK (NODE))->member)
 
 /* Nonzero for VAR_DECL and FUNCTION_DECL node means that `extern' was
    specified in its declaration.  */
-#define DECL_THIS_EXTERN(NODE) (DECL_LANG_FLAG_2(NODE))
+#define DECL_THIS_EXTERN(NODE) \
+  DECL_LANG_FLAG_2 (VAR_OR_FUNCTION_DECL_CHECK (NODE))
 
 /* Nonzero for VAR_DECL and FUNCTION_DECL node means that `static' was
    specified in its declaration.  */
-#define DECL_THIS_STATIC(NODE) (DECL_LANG_FLAG_6(NODE))
+#define DECL_THIS_STATIC(NODE) \
+  DECL_LANG_FLAG_6 (VAR_OR_FUNCTION_DECL_CHECK (NODE))
 
 /* Nonzero in FUNCTION_DECL means it is really an operator.
    Just used to communicate formatting information to dbxout.c.  */
-#define DECL_OPERATOR(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.operator_attr)
+#define DECL_OPERATOR(NODE) \
+  (DECL_LANG_SPECIFIC(FUNCTION_DECL_CHECK (NODE))->decl_flags.operator_attr)
 
 /* Nonzero if TYPE is an anonymous union or struct type.  We have to use a
    flag for this because "A union for which objects or pointers are
    declared is not an anonymous union" [class.union].  */
 #define ANON_AGGR_TYPE_P(NODE)                         \
-  (CLASS_TYPE_P (NODE) && TYPE_LANG_SPECIFIC (NODE)->type_flags.anon_aggr)
+  (CLASS_TYPE_P (NODE) && TYPE_LANG_SPECIFIC (NODE)->anon_aggr)
 #define SET_ANON_AGGR_TYPE_P(NODE)                     \
-  (TYPE_LANG_SPECIFIC (NODE)->type_flags.anon_aggr = 1)
+  (TYPE_LANG_SPECIFIC (NODE)->anon_aggr = 1)
+
+/* Nonzero if TYPE is an anonymous union type.  */
+#define ANON_UNION_TYPE_P(NODE) \
+  (TREE_CODE (NODE) == UNION_TYPE && ANON_AGGR_TYPE_P (NODE))
+
+/* For a VAR_DECL that is an anonymous union, these are the various
+   sub-variables that make up the anonymous union.  */
+#define DECL_ANON_UNION_ELEMS(NODE) DECL_ARGUMENTS ((NODE))
 
 #define UNKNOWN_TYPE LANG_TYPE
 
@@ -1873,7 +2357,7 @@ extern int flag_new_for_scope;
 #define DECL_VPARENT(NODE) ((NODE)->decl.arguments)
 #endif
 
-#define TYPE_WAS_ANONYMOUS(NODE) (TYPE_LANG_SPECIFIC (NODE)->type_flags.was_anonymous)
+#define TYPE_WAS_ANONYMOUS(NODE) (TYPE_LANG_SPECIFIC (NODE)->was_anonymous)
 
 /* C++: all of these are overloaded!  These apply only to TYPE_DECLs.  */
 
@@ -1898,12 +2382,22 @@ extern int flag_new_for_scope;
    For example, if a member that would normally be public in a
    derived class is made protected, then the derived class and the
    protected_access_node will appear in the DECL_ACCESS for the node.  */
-#define DECL_ACCESS(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.access)
+#define DECL_ACCESS(NODE) (DECL_LANG_SPECIFIC(NODE)->decl_flags.u2.access)
+
+/* Nonzero if the FUNCTION_DECL is a global constructor.  */
+#define DECL_GLOBAL_CTOR_P(NODE) \
+  (DECL_LANG_SPECIFIC ((NODE))->decl_flags.global_ctor_p)
 
-/* C++: all of these are overloaded!
-   These apply to PARM_DECLs and VAR_DECLs.  */
-#define DECL_REFERENCE_SLOT(NODE) ((tree)(NODE)->decl.arguments)
-#define SET_DECL_REFERENCE_SLOT(NODE,VAL) ((NODE)->decl.arguments=VAL)
+/* Nonzero if the FUNCTION_DECL is a global destructor.  */
+#define DECL_GLOBAL_DTOR_P(NODE) \
+  (DECL_LANG_SPECIFIC ((NODE))->decl_flags.global_dtor_p)
+
+/* If DECL_GLOBAL_CTOR_P or DECL_GLOBAL_DTOR_P holds, this macro
+   returns the initialization priority for the function.  Constructors
+   with lower numbers should be run first.  Destructors should be run
+   in the reverse order of constructors.  */
+#define GLOBAL_INIT_PRIORITY(NODE) \
+  (DECL_LANG_SPECIFIC ((NODE))->decl_flags.u2.init_priority)
 
 /* Accessor macros for C++ template decl nodes.  */
 
@@ -2004,6 +2498,18 @@ extern int flag_new_for_scope;
 #define DECL_DECLARES_TYPE_P(NODE) \
   (TREE_CODE (NODE) == TYPE_DECL || DECL_CLASS_TEMPLATE_P (NODE))
 
+/* Nonzero if NODE is the typedef implicitly generated for a type when
+   the type is declared.  (In C++, `struct S {};' is roughly equivalent
+   to `struct S {}; typedef struct S S;' in C.  This macro will hold
+   for the typedef indicated in this example.  Note that in C++, there
+   is a second implicit typedef for each class, in the scope of `S'
+   itself, so that you can `S::S'.  This macro does *not* hold for
+   those typedefs.  */
+#define DECL_IMPLICIT_TYPEDEF_P(NODE) \
+  (TREE_CODE ((NODE)) == TYPE_DECL && DECL_LANG_FLAG_2 ((NODE)))
+#define SET_DECL_IMPLICIT_TYPEDEF_P(NODE) \
+  (DECL_LANG_FLAG_2 ((NODE)) = 1)
+
 /* A `primary' template is one that has its own template header.  A
    member function of a class template is a template, but not primary.
    A member template is primary.  Friend templates are primary, too.  */
@@ -2065,7 +2571,7 @@ extern int flag_new_for_scope;
    i.e., an instantiation whose instantiation arguments involve
    template types.  */
 #define PARTIAL_INSTANTIATION_P(TYPE) \
-  (TYPE_LANG_SPECIFIC (TYPE)->type_flags.is_partial_instantiation)
+  (TYPE_LANG_SPECIFIC (TYPE)->is_partial_instantiation)
 
 /* Non-zero iff we are currently processing a declaration for an
    entity with its own template parameter list, and which is not a
@@ -2079,7 +2585,8 @@ extern int flag_new_for_scope;
 /* Nonzero if this VAR_DECL or FUNCTION_DECL has already been
    instantiated, i.e. its definition has been generated from the
    pattern given in the the template.  */
-#define DECL_TEMPLATE_INSTANTIATED(NODE) DECL_LANG_FLAG_1(NODE)
+#define DECL_TEMPLATE_INSTANTIATED(NODE) \
+  DECL_LANG_FLAG_1 (VAR_OR_FUNCTION_DECL_CHECK (NODE))
 
 /* We know what we're doing with this decl now.  */
 #define DECL_INTERFACE_KNOWN(NODE) DECL_LANG_FLAG_5 (NODE)
@@ -2101,49 +2608,115 @@ extern int flag_new_for_scope;
 
 #define THUNK_DELTA(DECL) ((DECL)->decl.frame_size.i)
 
-/* ...and for unexpanded-parameterized-type nodes.  */
-#define UPT_TEMPLATE(NODE)      TREE_PURPOSE(TYPE_VALUES(NODE))
-#define UPT_PARMS(NODE)         TREE_VALUE(TYPE_VALUES(NODE))
+/* DECL_NEEDED_P holds of a declaration when we need to emit its
+   definition.  This is true when the back-end tells us that
+   the symbol has been referenced in the generated code.  If, however,
+   we are not generating code, then it is also true when a symbol has
+   just been used somewhere, even if it's not really needed.  */
+#define DECL_NEEDED_P(DECL)                              \
+  (TREE_SYMBOL_REFERENCED (DECL_ASSEMBLER_NAME ((DECL)))) \
 
 /* An un-parsed default argument looks like an identifier.  */
-#define DEFARG_NODE_CHECK(t)   TREE_CHECK(t, DEFAULT_ARG) 
-#define DEFARG_LENGTH(NODE)    (DEFARG_NODE_CHECK(NODE)->identifier.length)
-#define DEFARG_POINTER(NODE)   (DEFARG_NODE_CHECK(NODE)->identifier.pointer)
+#define DEFARG_LENGTH(NODE)  (DEFAULT_ARG_CHECK(NODE)->identifier.length)
+#define DEFARG_POINTER(NODE) (DEFAULT_ARG_CHECK(NODE)->identifier.pointer)
 
 /* These macros provide convenient access to the various _STMT nodes
    created when parsing template declarations.  */
-#define IF_COND(NODE)           TREE_OPERAND (NODE, 0)
-#define THEN_CLAUSE(NODE)       TREE_OPERAND (NODE, 1)
-#define ELSE_CLAUSE(NODE)       TREE_OPERAND (NODE, 2)
-#define WHILE_COND(NODE)        TREE_OPERAND (NODE, 0)
-#define WHILE_BODY(NODE)        TREE_OPERAND (NODE, 1)
-#define DO_COND(NODE)           TREE_OPERAND (NODE, 0)
-#define DO_BODY(NODE)           TREE_OPERAND (NODE, 1)
-#define RETURN_EXPR(NODE)       TREE_OPERAND (NODE, 0)
-#define EXPR_STMT_EXPR(NODE)    TREE_OPERAND (NODE, 0)
-#define FOR_INIT_STMT(NODE)     TREE_OPERAND (NODE, 0)
-#define FOR_COND(NODE)          TREE_OPERAND (NODE, 1)
-#define FOR_EXPR(NODE)          TREE_OPERAND (NODE, 2)
-#define FOR_BODY(NODE)          TREE_OPERAND (NODE, 3)
-#define SWITCH_COND(NODE)       TREE_OPERAND (NODE, 0)
-#define SWITCH_BODY(NODE)       TREE_OPERAND (NODE, 1)
-#define CASE_LOW(NODE)          TREE_OPERAND (NODE, 0)
-#define CASE_HIGH(NODE)         TREE_OPERAND (NODE, 1)
-#define GOTO_DESTINATION(NODE)  TREE_OPERAND (NODE, 0)
-#define TRY_STMTS(NODE)         TREE_OPERAND (NODE, 0)
-#define TRY_HANDLERS(NODE)      TREE_OPERAND (NODE, 1)
-#define HANDLER_PARMS(NODE)     TREE_OPERAND (NODE, 0)
-#define HANDLER_BODY(NODE)      TREE_OPERAND (NODE, 1)
-#define COMPOUND_BODY(NODE)     TREE_OPERAND (NODE, 0)
-#define ASM_CV_QUAL(NODE)       TREE_OPERAND (NODE, 0)
-#define ASM_STRING(NODE)        TREE_OPERAND (NODE, 1)
-#define ASM_OUTPUTS(NODE)       TREE_OPERAND (NODE, 2)
-#define ASM_INPUTS(NODE)        TREE_OPERAND (NODE, 3)
-#define ASM_CLOBBERS(NODE)      TREE_OPERAND (NODE, 4)
+#define IF_COND(NODE)           TREE_OPERAND (IF_STMT_CHECK (NODE), 0)
+#define THEN_CLAUSE(NODE)       TREE_OPERAND (IF_STMT_CHECK (NODE), 1)
+#define ELSE_CLAUSE(NODE)       TREE_OPERAND (IF_STMT_CHECK (NODE), 2)
+#define WHILE_COND(NODE)        TREE_OPERAND (WHILE_STMT_CHECK (NODE), 0)
+#define WHILE_BODY(NODE)        TREE_OPERAND (WHILE_STMT_CHECK (NODE), 1)
+#define DO_COND(NODE)           TREE_OPERAND (DO_STMT_CHECK (NODE), 0)
+#define DO_BODY(NODE)           TREE_OPERAND (DO_STMT_CHECK (NODE), 1)
+#define RETURN_EXPR(NODE)       TREE_OPERAND (RETURN_STMT_CHECK (NODE), 0)
+#define EXPR_STMT_EXPR(NODE)    TREE_OPERAND (EXPR_STMT_CHECK (NODE), 0)
+#define FOR_INIT_STMT(NODE)     TREE_OPERAND (FOR_STMT_CHECK (NODE), 0)
+#define FOR_COND(NODE)          TREE_OPERAND (FOR_STMT_CHECK (NODE), 1)
+#define FOR_EXPR(NODE)          TREE_OPERAND (FOR_STMT_CHECK (NODE), 2)
+#define FOR_BODY(NODE)          TREE_OPERAND (FOR_STMT_CHECK (NODE), 3)
+#define SWITCH_COND(NODE)       TREE_OPERAND (SWITCH_STMT_CHECK (NODE), 0)
+#define SWITCH_BODY(NODE)       TREE_OPERAND (SWITCH_STMT_CHECK (NODE), 1)
+#define CASE_LOW(NODE)          TREE_OPERAND (CASE_LABEL_CHECK (NODE), 0)
+#define CASE_HIGH(NODE)         TREE_OPERAND (CASE_LABEL_CHECK (NODE), 1)
+#define GOTO_DESTINATION(NODE)  TREE_OPERAND (GOTO_STMT_CHECK (NODE), 0)
+#define TRY_STMTS(NODE)         TREE_OPERAND (TRY_BLOCK_CHECK (NODE), 0)
+#define TRY_HANDLERS(NODE)      TREE_OPERAND (TRY_BLOCK_CHECK (NODE), 1)
+#define CLEANUP_P(NODE)         TREE_LANG_FLAG_0 (TRY_BLOCK_CHECK (NODE))
+/* Nonzero if this try block is a function try block.  */
+#define FN_TRY_BLOCK_P(NODE)    TREE_LANG_FLAG_3 (TRY_BLOCK_CHECK (NODE))
+#define HANDLER_PARMS(NODE)     TREE_OPERAND (HANDLER_CHECK (NODE), 0)
+#define HANDLER_BODY(NODE)      TREE_OPERAND (HANDLER_CHECK (NODE), 1)
+#define COMPOUND_BODY(NODE)     TREE_OPERAND (COMPOUND_STMT_CHECK (NODE), 0)
+#define ASM_CV_QUAL(NODE)       TREE_OPERAND (ASM_STMT_CHECK (NODE), 0)
+#define ASM_STRING(NODE)        TREE_OPERAND (ASM_STMT_CHECK (NODE), 1)
+#define ASM_OUTPUTS(NODE)       TREE_OPERAND (ASM_STMT_CHECK (NODE), 2)
+#define ASM_INPUTS(NODE)        TREE_OPERAND (ASM_STMT_CHECK (NODE), 3)
+#define ASM_CLOBBERS(NODE)      TREE_OPERAND (ASM_STMT_CHECK (NODE), 4)
+#define DECL_STMT_DECL(NODE)    TREE_OPERAND (DECL_STMT_CHECK (NODE), 0)
+#define STMT_EXPR_STMT(NODE)    TREE_OPERAND (STMT_EXPR_CHECK (NODE), 0)
+#define SUBOBJECT_CLEANUP(NODE) TREE_OPERAND (SUBOBJECT_CHECK (NODE), 0)
+#define CLEANUP_DECL(NODE)      TREE_OPERAND (CLEANUP_STMT_CHECK (NODE), 0)
+#define CLEANUP_EXPR(NODE)      TREE_OPERAND (CLEANUP_STMT_CHECK (NODE), 1)
+#define START_CATCH_TYPE(NODE)  TREE_TYPE (START_CATCH_STMT_CHECK (NODE))
+#define LABEL_STMT_LABEL(NODE)  TREE_OPERAND (LABEL_STMT_CHECK (NODE), 0)
+
+/* Nonzero if this SCOPE_STMT is for the beginning of a scope.  */
+#define SCOPE_BEGIN_P(NODE) \
+  (TREE_LANG_FLAG_0 (SCOPE_STMT_CHECK (NODE))) 
+
+/* Nonzero if this SCOPE_STMT is for the end of a scope.  */
+#define SCOPE_END_P(NODE) \
+  (!SCOPE_BEGIN_P (SCOPE_STMT_CHECK (NODE)))
+
+/* Nonzero for a SCOPE_STMT if there were no variables in this scope.  */
+#define SCOPE_NULLIFIED_P(NODE) \
+  (TREE_LANG_FLAG_3 (SCOPE_STMT_CHECK (NODE)))
+
+/* Nonzero for a SCOPE_STMT if this statement is for a partial scope.
+   For example, in:
+  
+     S s;
+     l:
+     S s2;
+     goto l;
+
+   there is (implicitly) a new scope after `l', even though there are
+   no curly braces.  In particular, when we hit the goto, we must
+   destroy s2 and then re-construct it.  For the implicit scope,
+   SCOPE_PARTIAL_P will be set.  */
+#define SCOPE_PARTIAL_P(NODE) \
+  (TREE_LANG_FLAG_4 (SCOPE_STMT_CHECK (NODE)))
+
+/* Nonzero for an ASM_STMT if the assembly statement is volatile.  */
+#define ASM_VOLATILE_P(NODE)                   \
+  (ASM_CV_QUAL (ASM_STMT_CHECK (NODE)) != NULL_TREE)
+
+/* The line-number at which a statement began.  But if
+   STMT_LINENO_FOR_FN_P does holds, then this macro gives the
+   line number for the end of the current function instead.  */
+#define STMT_LINENO(NODE)                      \
+  (TREE_COMPLEXITY ((NODE)))
+
+/* If non-zero, the STMT_LINENO for NODE is the line at which the
+   function ended.  */
+#define STMT_LINENO_FOR_FN_P(NODE)             \
+  (TREE_LANG_FLAG_2 ((NODE)))
+
+/* The parameters for a call-declarator.  */
+#define CALL_DECLARATOR_PARMS(NODE) \
+  (TREE_PURPOSE (TREE_OPERAND ((NODE), 1)))
+
+/* The cv-qualifiers for a call-declarator.  */
+#define CALL_DECLARATOR_QUALS(NODE) \
+  (TREE_VALUE (TREE_OPERAND ((NODE), 1)))
+
+/* The exception-specification for a call-declarator.  */
+#define CALL_DECLARATOR_EXCEPTION_SPEC(NODE) \
+  (TREE_TYPE ((NODE)))
 
 /* An enumeration of the kind of tags that C++ accepts.  */
-enum tag_types { record_type, class_type, union_type, enum_type,
-                  signature_type };
+enum tag_types { record_type, class_type, union_type, enum_type };
 
 /* The various kinds of lvalues we distinguish.  */
 typedef enum cp_lvalue_kind {
@@ -2162,6 +2735,9 @@ extern int strict_prototypes_lang_c, strict_prototypes_lang_cplusplus;
    applies, use the value of the label.  */
 extern int flag_labels_ok;
 
+/* Nonzero means allow Microsoft extensions without a pedwarn.  */
+extern int flag_ms_extensions;
+
 /* Non-zero means to collect statistics which might be expensive
    and to print them when we are done.  */
 extern int flag_detailed_statistics;
@@ -2220,19 +2796,12 @@ extern tree type_for_size                       PROTO((unsigned, int));
 extern int c_get_alias_set                      PROTO((tree));
 
 /* in decl{2}.c */
-extern tree this_identifier;
-extern tree ctor_identifier, dtor_identifier;
-extern tree pfn_identifier;
-extern tree index_identifier;
-extern tree delta_identifier;
-extern tree delta2_identifier;
-extern tree pfn_or_delta2_identifier;
-extern tree tag_identifier;
-extern tree vt_off_identifier;
-
 /* A node that is a list (length 1) of error_mark_nodes.  */
 extern tree error_mark_list;
 
+/* A list of virtual function tables we must make sure to write out.  */
+extern tree pending_vtables;
+
 /* Node for "pointer to (virtual) function".
    This may be distinct from ptr_type_node so gdb can distinguish them.  */
 #define vfunc_ptr_type_node \
@@ -2242,8 +2811,6 @@ extern tree error_mark_list;
 /* For building calls to `delete'.  */
 extern tree integer_two_node, integer_three_node;
 
-extern tree null_node;
-
 extern tree anonymous_namespace_name;
 
 /* in pt.c  */
@@ -2258,10 +2825,6 @@ typedef enum unification_kind_t {
   DEDUCE_EXACT
 } unification_kind_t;
 
-extern tree current_template_parms;
-extern HOST_WIDE_INT processing_template_decl;
-extern tree last_tree;
-
 /* The template currently being instantiated, and where the instantiation
    was triggered.  */
 struct tinst_level
@@ -2272,41 +2835,19 @@ struct tinst_level
   struct tinst_level *next;
 };
 
-extern int minimal_parse_mode;
-
 extern void maybe_print_template_context       PROTO ((void));
 
 /* in class.c */
 
-/* When parsing a class definition, the access specifier most recently
-   given by the user, or, if no access specifier was given, the
-   default value appropriate for the kind of class (i.e., struct,
-   class, or union).  */
-extern tree current_access_specifier;
-
-extern tree current_class_name;
-extern tree current_class_type;
-extern tree current_class_ptr;
-extern tree previous_class_type;
-extern tree current_class_ref;
 extern int current_class_depth;
 
-extern tree current_lang_name;
-extern tree lang_name_cplusplus, lang_name_c, lang_name_java;
-
-/* The low-water mark on the class-cache obstack.  */
-extern char *class_cache_firstobj;
-
 /* Points to the name of that function. May not be the DECL_NAME
    of CURRENT_FUNCTION_DECL due to overloading */
 extern tree original_function_name;
 
 /* in init.c  */
 extern tree global_base_init_list;
-extern tree current_base_init_list, current_member_init_list;
 
-extern int current_function_just_assigned_this;
-extern int current_function_parms_stored;
 \f
 /* Here's where we control how name mangling takes place.  */
 
@@ -2430,21 +2971,6 @@ extern int current_function_parms_stored;
 #define VTABLE_PFN_NAME                "__pfn"
 #define VTABLE_DELTA2_NAME     "__delta2"
 
-#define SIGNATURE_FIELD_NAME   "__s_"
-#define SIGNATURE_FIELD_NAME_FORMAT "__s_%s"
-#define SIGNATURE_OPTR_NAME    "__optr"
-#define SIGNATURE_SPTR_NAME    "__sptr"
-#define SIGNATURE_POINTER_NAME "__sp_"
-#define SIGNATURE_POINTER_NAME_FORMAT "__%s%s%ssp_%s"
-#define SIGNATURE_REFERENCE_NAME "__sr_"
-#define SIGNATURE_REFERENCE_NAME_FORMAT "__%s%s%ssr_%s"
-
-#define SIGTABLE_PTR_TYPE      "__sigtbl_ptr_type"
-#define SIGTABLE_NAME_FORMAT   "__st_%s_%s"
-#define SIGTABLE_NAME_FORMAT_LONG "__st_%s_%s_%d"
-#define SIGTABLE_TAG_NAME      "__tag"
-#define SIGTABLE_VB_OFF_NAME   "__vb_off"
-#define SIGTABLE_VT_OFF_NAME   "__vt_off"
 #define EXCEPTION_CLEANUP_NAME         "exception cleanup"
 
 #define THIS_NAME_P(ID_NODE) (strcmp(IDENTIFIER_POINTER (ID_NODE), "this") == 0)
@@ -2499,20 +3025,6 @@ extern int current_function_parms_stored;
     && MAIN_NAME_P (DECL_NAME (NODE)))
 
 \f
-/* Define the sets of attributes that member functions and baseclasses
-   can have.  These are sensible combinations of {public,private,protected}
-   cross {virtual,non-virtual}.  */
-
-/* in class.c.  */
-extern tree access_default_node; /* 0 */
-extern tree access_public_node; /* 1 */
-extern tree access_protected_node; /* 2 */
-extern tree access_private_node; /* 3 */
-extern tree access_default_virtual_node; /* 4 */
-extern tree access_public_virtual_node; /* 5 */
-extern tree access_protected_virtual_node; /* 6 */
-extern tree access_private_virtual_node; /* 7 */
-
 /* Things for handling inline functions.  */
 
 struct pending_inline
@@ -2534,8 +3046,7 @@ struct pending_inline
 /* in method.c */
 extern struct pending_inline *pending_inlines;
 
-/* Positive values means that we cannot make optimizing assumptions about
-   `this'.  Negative values means we know `this' to be of static type.  */
+/* Negative values means we know `this' to be of static type.  */
 
 extern int flag_this_is_variable;
 
@@ -2580,9 +3091,6 @@ extern int at_eof;
 
 enum overload_flags { NO_SPECIAL = 0, DTOR_FLAG, OP_FLAG, TYPENAME_FLAG };
 
-/* The following two can be derived from the previous one */
-extern tree current_class_name;        /* IDENTIFIER_NODE: name of current class */
-
 /* Some macros for char-based bitfields.  */
 #define B_SET(a,x) (a[x>>3] |= (1 << (x&7)))
 #define B_CLR(a,x) (a[x>>3] &= ~(1 << (x&7)))
@@ -2707,6 +3215,14 @@ extern tree current_class_name;  /* IDENTIFIER_NODE: name of current class */
 #define PUSH_USING           2  /* We are pushing this DECL as the
                                   result of a using declaration.  */
 
+/* Used with start function.  */
+#define SF_DEFAULT           0  /* No flags.  */
+#define SF_PRE_PARSED        1  /* The function declaration has
+                                  already been parsed.  */
+#define SF_INCLASS_INLINE    2  /* The function is an inline, defined
+                                  in the class body.  */
+#define SF_EXPAND            4  /* Generate RTL for this function.  */
+
 /* Returns nonzero iff TYPE1 and TYPE2 are the same type, in the usual
    sense of `same'.  */
 #define same_type_p(type1, type2) \
@@ -2719,11 +3235,13 @@ extern tree current_class_name; /* IDENTIFIER_NODE: name of current class */
   comptypes ((type1), (type2), COMPARE_BASE)
 
 /* These macros are used to access a TEMPLATE_PARM_INDEX.  */
-#define TEMPLATE_PARM_IDX(NODE) (((template_parm_index*) NODE)->index)
-#define TEMPLATE_PARM_LEVEL(NODE) (((template_parm_index*) NODE)->level)
+#define TEMPLATE_PARM_INDEX_CAST(NODE) \
+       ((template_parm_index*)TEMPLATE_PARM_INDEX_CHECK (NODE))
+#define TEMPLATE_PARM_IDX(NODE) (TEMPLATE_PARM_INDEX_CAST (NODE)->index)
+#define TEMPLATE_PARM_LEVEL(NODE) (TEMPLATE_PARM_INDEX_CAST (NODE)->level)
 #define TEMPLATE_PARM_DESCENDANTS(NODE) (TREE_CHAIN (NODE))
-#define TEMPLATE_PARM_ORIG_LEVEL(NODE) (((template_parm_index*) NODE)->orig_level)
-#define TEMPLATE_PARM_DECL(NODE) (((template_parm_index*) NODE)->decl)
+#define TEMPLATE_PARM_ORIG_LEVEL(NODE) (TEMPLATE_PARM_INDEX_CAST (NODE)->orig_level)
+#define TEMPLATE_PARM_DECL(NODE) (TEMPLATE_PARM_INDEX_CAST (NODE)->decl)
 
 /* These macros are for accessing the fields of TEMPLATE_TYPE_PARM 
    and TEMPLATE_TEMPLATE_PARM nodes.  */
@@ -2737,11 +3255,35 @@ extern tree current_class_name; /* IDENTIFIER_NODE: name of current class */
 #define TEMPLATE_TYPE_DECL(NODE) \
   (TEMPLATE_PARM_DECL (TEMPLATE_TYPE_PARM_INDEX (NODE)))
 
+/* Control stringification of trees (types, decls & exprs).
+   Bit or them together.  */
+enum tree_string_flags
+{
+    TS_PLAIN,                    /* nothing special */
+    TS_CHASE_TYPEDEFS = 1 <<  0, /* look through typedefs */
+    TS_DECORATE       = 1 <<  1, /* decorate things */
+    TS_FUNC_NORETURN  = 1 <<  2, /* inhibit function return type */
+    TS_FUNC_THROW     = 1 <<  3, /* show throw spec */
+    TS_PARM_DEFAULTS  = 1 <<  4, /* show parm defaults */
+    TS_EXPR_PARENS    = 1 <<  5, /* enclose in parens */
+    TS_AGGR_TAGS      = 1 <<  6, /* show struct tags */
+    TS_DECL_TYPE      = 1 <<  7, /* show decl's type */
+    TS_FUNC_SCOPE     = 1 <<  8, /* show function scope */
+    TS_PEDANTIC_NAME  = 1 <<  9, /* pedantically name things */
+    TS_TEMPLATE_PREFIX= 1 << 10, /* show template <parms> prefix */
+    
+    /* Internal use flags */
+    TS_TEMPLATE_PARM  = 1 << 11, /* decl is really a non-type template parm */
+    TS_TEMPLATE_PLAIN = 1 << 12, /* don't decorate primary template_name */
+    
+    TS_NEXT_BIT       = 13       /* next available bit */
+};
+
 /* in lex.c  */
 /* Indexed by TREE_CODE, these tables give C-looking names to
    operators represented by TREE_CODES.  For example,
    opname_tab[(int) MINUS_EXPR] == "-".  */
-extern char **opname_tab, **assignop_tab;
+extern const char **opname_tab, **assignop_tab;
 \f
 /* in call.c */
 extern int check_dtor_name                     PROTO((tree, tree));
@@ -2765,8 +3307,12 @@ extern int can_convert_arg                       PROTO((tree, tree, tree));
 extern int enforce_access                       PROTO((tree, tree));
 extern tree convert_default_arg                 PROTO((tree, tree, tree));
 extern tree convert_arg_to_ellipsis             PROTO((tree));
+extern tree build_x_va_arg                      PROTO((tree, tree));
+extern tree convert_type_from_ellipsis          PROTO((tree));
 extern int is_properly_derived_from             PROTO((tree, tree));
 extern tree initialize_reference                PROTO((tree, tree));
+extern tree strip_top_quals                     PROTO((tree));
+extern tree perform_implicit_conversion         PROTO((tree, tree));
 
 /* in class.c */
 extern tree build_vbase_path                   PROTO((enum tree_code, tree, tree, tree, int));
@@ -2789,7 +3335,6 @@ extern void push_lang_context                     PROTO((tree));
 extern void pop_lang_context                   PROTO((void));
 extern tree instantiate_type                   PROTO((tree, tree, int));
 extern void print_class_statistics             PROTO((void));
-extern void push_cache_obstack                 PROTO((void));
 extern unsigned HOST_WIDE_INT skip_rtti_stuff  PROTO((tree *, tree));
 extern void build_self_reference               PROTO((void));
 extern void warn_hidden                                PROTO((tree));
@@ -2807,6 +3352,7 @@ extern tree convert_pointer_to_real               PROTO((tree, tree));
 extern tree convert_pointer_to                 PROTO((tree, tree));
 extern tree ocp_convert                                PROTO((tree, tree, int, int));
 extern tree cp_convert                         PROTO((tree, tree));
+extern tree convert_to_void                    PROTO((tree, const char */*implicit context*/));
 extern tree convert                            PROTO((tree, tree));
 extern tree convert_force                      PROTO((tree, tree, int));
 extern tree build_type_conversion              PROTO((tree, tree, int));
@@ -2820,22 +3366,20 @@ extern void set_identifier_local_value          PROTO((tree, tree));
 extern int global_bindings_p                   PROTO((void));
 extern int toplevel_bindings_p                 PROTO((void));
 extern int namespace_bindings_p                        PROTO((void));
-extern void keep_next_level                    PROTO((void));
+extern void keep_next_level                    PROTO((int));
 extern int kept_level_p                                PROTO((void));
-extern void declare_parm_level                 PROTO((void));
 extern void declare_pseudo_global_level                PROTO((void));
 extern int pseudo_global_level_p               PROTO((void));
 extern void set_class_shadows                  PROTO((tree));
 extern void pushlevel                          PROTO((int));
 extern void note_level_for_for                 PROTO((void));
-extern void pushlevel_temporary                        PROTO((int));
-extern tree poplevel                           PROTO((int, int, int));
 extern void resume_level                       PROTO((struct binding_level *));
 extern void delete_block                       PROTO((tree));
 extern void insert_block                       PROTO((tree));
 extern void add_block_current_level            PROTO((tree));
 extern void set_block                          PROTO((tree));
 extern void pushlevel_class                    PROTO((void));
+extern void poplevel_class                      PROTO((void));
 extern void print_binding_stack                        PROTO((void));
 extern void print_binding_level                        PROTO((struct binding_level *));
 extern void push_namespace                     PROTO((tree));
@@ -2865,7 +3409,7 @@ extern tree push_using_directive                PROTO((tree));
 extern void push_class_level_binding           PROTO((tree, tree));
 extern tree implicitly_declare                 PROTO((tree));
 extern tree lookup_label                       PROTO((tree));
-extern tree shadow_label                       PROTO((tree));
+extern tree declare_local_label                 PROTO((tree));
 extern tree define_label                       PROTO((char *, int, tree));
 extern void push_switch                                PROTO((void));
 extern void pop_switch                         PROTO((void));
@@ -2880,7 +3424,7 @@ extern tree namespace_binding                   PROTO((tree, tree));
 extern void set_namespace_binding               PROTO((tree, tree, tree));
 extern tree lookup_namespace_name              PROTO((tree, tree));
 extern tree build_typename_type                 PROTO((tree, tree, tree, tree));
-extern tree make_typename_type                 PROTO((tree, tree));
+extern tree make_typename_type                 PROTO((tree, tree, int));
 extern tree lookup_name_nonclass               PROTO((tree));
 extern tree lookup_function_nonclass            PROTO((tree, tree));
 extern tree lookup_name                                PROTO((tree, int));
@@ -2890,14 +3434,15 @@ extern tree lookup_name_namespace_only          PROTO((tree));
 extern void begin_only_namespace_names          PROTO((void));
 extern void end_only_namespace_names            PROTO((void));
 extern tree namespace_ancestor                 PROTO((tree, tree));
-extern int  lookup_using_namespace              PROTO((tree,tree,tree,tree,int));
-extern int  qualified_lookup_using_namespace    PROTO((tree,tree,tree,int));
-extern tree auto_function                      PROTO((tree, tree, enum built_in_function));
+extern tree unqualified_namespace_lookup       PROTO((tree, int, tree *));
+extern int  lookup_using_namespace              PROTO((tree, tree, tree, tree, int, tree *));
+extern int  qualified_lookup_using_namespace    PROTO((tree, tree, tree, int));
+extern tree auto_function                      PROTO((tree, tree));
 extern void init_decl_processing               PROTO((void));
 extern int init_type_desc                      PROTO((void));
-extern tree define_function
-       PROTO((const char *, tree, enum built_in_function,
-              void (*) (tree), const char *));  
+extern tree define_function                    PROTO((const char *, tree,
+                                                      void (*) (tree),
+                                                      const char *));
 extern tree check_tag_decl                     PROTO((tree));
 extern void shadow_tag                         PROTO((tree));
 extern tree groktypename                       PROTO((tree));
@@ -2905,7 +3450,10 @@ extern tree start_decl                           PROTO((tree, tree, int, tree, tree));
 extern void start_decl_1                       PROTO((tree));
 extern void cp_finish_decl                     PROTO((tree, tree, tree, int, int));
 extern void finish_decl                                PROTO((tree, tree, tree));
+extern void maybe_inject_for_scope_var          PROTO((tree));
+extern void initialize_local_var                PROTO((tree, tree, int));
 extern void expand_static_init                 PROTO((tree, tree));
+extern tree start_handler_parms                 PROTO((tree, tree));
 extern int complete_array_type                 PROTO((tree, tree, int));
 extern tree build_ptrmemfunc_type              PROTO((tree));
 /* the grokdeclarator prototype is in decl.h */
@@ -2922,8 +3470,8 @@ extern tree build_enumerator                      PROTO((tree, tree, tree));
 extern int start_function                      PROTO((tree, tree, tree, int));
 extern void expand_start_early_try_stmts       PROTO((void));
 extern void store_parm_decls                   PROTO((void));
-extern void store_return_init                  PROTO((tree, tree));
-extern void finish_function                    PROTO((int, int, int));
+extern void store_return_init                  PROTO((tree));
+extern tree finish_function                    PROTO((int, int));
 extern tree start_method                       PROTO((tree, tree, tree));
 extern tree finish_method                      PROTO((tree));
 extern void hack_incomplete_structures         PROTO((tree));
@@ -2931,8 +3479,6 @@ extern tree maybe_build_cleanup_and_delete        PROTO((tree));
 extern tree maybe_build_cleanup                        PROTO((tree));
 extern void cplus_expand_expr_stmt             PROTO((tree));
 extern void finish_stmt                                PROTO((void));
-extern void push_cp_function_context           PROTO((tree));
-extern void pop_cp_function_context            PROTO((tree));
 extern int in_function_p                       PROTO((void));
 extern void replace_defarg                     PROTO((tree, tree));
 extern void print_other_binding_stack          PROTO((struct binding_level *));
@@ -2957,8 +3503,15 @@ typedef int (*walk_namespaces_fn)               PROTO((tree, void *));
 extern int walk_namespaces                      PROTO((walk_namespaces_fn,
                                                       void *));
 extern int wrapup_globals_for_namespace         PROTO((tree, void *));
+extern tree cp_namespace_decls                  PROTO((tree));
+extern tree create_implicit_typedef             PROTO((tree, tree));
+extern tree maybe_push_decl                     PROTO((tree));
+extern void emit_local_var                      PROTO((tree));
+extern tree build_target_expr                   PROTO((tree, tree));
+extern void make_rtl_for_local_static           PROTO((tree));
 
 /* in decl2.c */
+extern void init_decl2                         PROTO((void));
 extern int check_java_method                   PROTO((tree));
 extern int lang_decode_option                  PROTO((int, char **));
 extern tree grok_method_quals                  PROTO((tree, tree, tree));
@@ -2982,9 +3535,7 @@ extern tree constructor_name_full         PROTO((tree));
 extern tree constructor_name                   PROTO((tree));
 extern void setup_vtbl_ptr                     PROTO((void));
 extern void mark_inline_for_output             PROTO((tree));
-extern void clear_temp_name                    PROTO((void));
 extern tree get_temp_name                      PROTO((tree, int));
-extern tree get_temp_regvar                    PROTO((tree, tree));
 extern void finish_anon_union                  PROTO((tree));
 extern tree finish_table                       PROTO((tree, tree, tree, int));
 extern void finish_builtin_type                        PROTO((tree, const char *,
@@ -3020,6 +3571,9 @@ extern tree handle_class_head                     PROTO((tree, tree, tree));
 extern tree lookup_arg_dependent                PROTO((tree, tree, tree));
 extern void finish_static_data_member_decl      PROTO((tree, tree, tree, int, int));
 
+/* in parse.y */
+extern void cp_parse_init                      PROTO((void));
+
 /* in errfn.c */
 /* The cp_* functions aren't suitable for ATTRIBUTE_PRINTF. */
 extern void cp_error                           PVPROTO((const char *, ...));
@@ -3034,32 +3588,24 @@ extern void cp_deprecated                       PROTO((const char*));
 
 /* in error.c */
 extern void init_error                         PROTO((void));
-extern char *fndecl_as_string                  PROTO((tree, int));
-extern char *type_as_string                    PROTO((tree, int));
-extern char *type_as_string_real               PROTO((tree, int, int));
-extern char *args_as_string                    PROTO((tree, int));
-extern char *decl_as_string                    PROTO((tree, int));
-extern char *expr_as_string                    PROTO((tree, int));
-extern char *code_as_string                    PROTO((enum tree_code, int));
-extern char *language_as_string                        PROTO((enum languages, int));
-extern char *parm_as_string                    PROTO((int, int));
-extern char *op_as_string                      PROTO((enum tree_code, int));
-extern char *assop_as_string                   PROTO((enum tree_code, int));
-extern char *cv_as_string                      PROTO((tree, int));
-extern char *lang_decl_name                    PROTO((tree, int));
-extern char *cp_file_of                                PROTO((tree));
+extern const char *type_as_string              PROTO((tree, enum tree_string_flags));
+extern const char *decl_as_string              PROTO((tree, enum tree_string_flags));
+extern const char *expr_as_string              PROTO((tree, enum tree_string_flags));
+extern const char *context_as_string            PROTO((tree, enum tree_string_flags));
+extern const char *lang_decl_name              PROTO((tree, int));
+extern const char *cp_file_of                  PROTO((tree));
 extern int cp_line_of                          PROTO((tree));
 
 /* in except.c */
 extern void init_exception_processing          PROTO((void));
-extern void expand_start_catch_block           PROTO((tree, tree));
-extern void expand_end_catch_block             PROTO((void));
+extern tree expand_start_catch_block           PROTO((tree));
+extern void expand_end_catch_block             PROTO((tree));
 extern void expand_builtin_throw               PROTO((void));
-extern void expand_start_eh_spec               PROTO((void));
+extern tree expand_start_eh_spec               PROTO((void));
+extern void expand_end_eh_spec                 PROTO((tree, tree));
 extern void expand_exception_blocks            PROTO((void));
 extern tree start_anon_func                    PROTO((void));
 extern void end_anon_func                      PROTO((void));
-extern void expand_throw                       PROTO((tree));
 extern tree build_throw                                PROTO((tree));
 extern void mark_all_runtime_matches            PROTO((void));
 
@@ -3080,10 +3626,10 @@ extern tree do_friend                           PROTO((tree, tree, tree, tree, tree, enum overload_flag
 /* in init.c */
 extern void init_init_processing               PROTO((void));
 extern void expand_direct_vtbls_init           PROTO((tree, tree, int, int, tree));
-extern void emit_base_init                     PROTO((tree, int));
+extern tree emit_base_init                     PROTO((tree));
 extern void check_base_init                    PROTO((tree));
 extern void expand_member_init                 PROTO((tree, tree, tree));
-extern void expand_aggr_init                   PROTO((tree, tree, int));
+extern tree build_aggr_init                    PROTO((tree, tree, int));
 extern int is_aggr_typedef                     PROTO((tree, int));
 extern int is_aggr_type                                PROTO((tree, int));
 extern tree get_aggr_from_typedef              PROTO((tree, int));
@@ -3094,11 +3640,14 @@ extern tree resolve_offset_ref                  PROTO((tree));
 extern tree decl_constant_value                        PROTO((tree));
 extern tree build_new                          PROTO((tree, tree, tree, int));
 extern tree build_new_1                                PROTO((tree));
-extern tree expand_vec_init                    PROTO((tree, tree, tree, tree, int));
+extern tree build_vec_init                     PROTO((tree, tree, tree, tree, int));
 extern tree build_x_delete                     PROTO((tree, int, tree));
 extern tree build_delete                       PROTO((tree, tree, tree, int, int));
 extern tree build_vbase_delete                 PROTO((tree, tree));
 extern tree build_vec_delete                   PROTO((tree, tree, tree, tree, int));
+extern tree create_temporary_var                PROTO((tree));
+extern void begin_init_stmts                    PROTO((tree *, tree *));
+extern tree finish_init_stmts                   PROTO((tree, tree));
 
 /* in input.c */
 
@@ -3108,7 +3657,7 @@ extern tree make_pointer_declarator               PROTO((tree, tree));
 extern tree make_reference_declarator          PROTO((tree, tree));
 extern tree make_call_declarator               PROTO((tree, tree, tree, tree));
 extern void set_quals_and_spec                 PROTO((tree, tree, tree));
-extern char *operator_name_string              PROTO((tree));
+extern const char *operator_name_string                PROTO((tree));
 extern void lang_init                          PROTO((void));
 extern void lang_finish                                PROTO((void));
 #if 0
@@ -3118,7 +3667,7 @@ extern void reinit_parse_for_function             PROTO((void));
 extern void print_parse_statistics             PROTO((void));
 extern void extract_interface_info             PROTO((void));
 extern void do_pending_inlines                 PROTO((void));
-extern void process_next_inline                        PROTO((tree));
+extern void process_next_inline                        PROTO((struct pending_inline *));
 extern struct pending_input *save_pending_input PROTO((void));
 extern void restore_pending_input              PROTO((struct pending_input *));
 extern void yyungetc                           PROTO((int, int));
@@ -3138,9 +3687,8 @@ extern int real_yylex                             PROTO((void));
 extern int is_rid                              PROTO((tree));
 extern tree build_lang_decl                    PROTO((enum tree_code, tree, tree));
 extern void retrofit_lang_decl                 PROTO((tree));
-extern tree build_lang_field_decl              PROTO((enum tree_code, tree, tree));
 extern void copy_lang_decl                     PROTO((tree));
-extern tree make_lang_type                     PROTO((enum tree_code));
+extern tree cp_make_lang_type                  PROTO((enum tree_code));
 extern void dump_time_statistics               PROTO((void));
 extern void compiler_error                     PVPROTO((const char *, ...))
   ATTRIBUTE_PRINTF_1;
@@ -3171,9 +3719,10 @@ extern tree hack_identifier                      PROTO((tree, tree));
 extern tree make_thunk                         PROTO((tree, int));
 extern void emit_thunk                         PROTO((tree));
 extern void synthesize_method                  PROTO((tree));
-extern tree get_id_2                           PROTO((char *, tree));
+extern tree get_id_2                           PROTO((const char *, tree));
 
 /* in pt.c */
+extern void init_pt                             PROTO ((void));
 extern void check_template_shadow              PROTO ((tree));
 extern tree innermost_args                     PROTO ((tree));
 extern tree tsubst                             PROTO ((tree, tree, int, tree));
@@ -3210,16 +3759,11 @@ extern void mark_class_instantiated             PROTO((tree, int));
 extern void do_decl_instantiation              PROTO((tree, tree, tree));
 extern void do_type_instantiation              PROTO((tree, tree));
 extern tree instantiate_decl                   PROTO((tree));
-extern tree do_poplevel                                PROTO((void));
 extern tree get_bindings                       PROTO((tree, tree, tree));
-/* CONT ... */
 extern void add_tree                           PROTO((tree));
-extern void begin_tree                          PROTO((void));
-extern void end_tree                            PROTO((void));
 extern void add_maybe_template                 PROTO((tree, tree));
 extern void pop_tinst_level                    PROTO((void));
 extern int more_specialized_class              PROTO((tree, tree));
-extern void do_pushlevel                       PROTO((void));
 extern int is_member_template                   PROTO((tree));
 extern int template_parms_equal                 PROTO((tree, tree));
 extern int comp_template_parms                  PROTO((tree, tree));
@@ -3231,9 +3775,9 @@ extern void maybe_check_template_type           PROTO((tree));
 extern tree most_specialized_instantiation      PROTO((tree, tree));
 extern void print_candidates                    PROTO((tree));
 extern int instantiate_pending_templates        PROTO((void));
+extern tree tsubst_default_argument             PROTO((tree, tree, tree));
+extern tree most_general_template              PROTO((tree));
 
-extern int processing_specialization;
-extern int processing_explicit_instantiation;
 extern int processing_template_parmlist;
 
 /* in repo.c */
@@ -3258,6 +3802,7 @@ extern int types_overlap_p                        PROTO((tree, tree));
 extern tree get_vbase                          PROTO((tree, tree));
 extern tree get_binfo                          PROTO((tree, tree, int));
 extern int get_base_distance                   PROTO((tree, tree, int, tree *));
+extern tree get_dynamic_cast_base_type          PROTO((tree, tree));
 extern int accessible_p                         PROTO((tree, tree));
 extern tree lookup_field                       PROTO((tree, tree, int, int));
 extern int lookup_fnfields_1                    PROTO((tree, tree));
@@ -3278,8 +3823,10 @@ extern void print_search_statistics              PROTO((void));
 extern void init_search_processing             PROTO((void));
 extern void reinit_search_statistics           PROTO((void));
 extern tree current_scope                      PROTO((void));
+extern int at_function_scope_p                  PROTO((void));
 extern tree lookup_conversions                 PROTO((tree));
 extern tree binfo_for_vtable                   PROTO((tree));
+extern int  binfo_from_vbase                   PROTO((tree));
 extern tree dfs_walk                            PROTO((tree, 
                                                       tree (*)(tree, void *),
                                                       tree (*) (tree, void *),
@@ -3309,23 +3856,32 @@ extern void finish_for_expr                     PROTO((tree, tree));
 extern void finish_for_stmt                     PROTO((tree, tree));
 extern void finish_break_stmt                   PROTO((void));
 extern void finish_continue_stmt                PROTO((void));
-extern void begin_switch_stmt                   PROTO((void));
-extern tree finish_switch_cond                  PROTO((tree));
+extern tree begin_switch_stmt                   PROTO((void));
+extern void finish_switch_cond                  PROTO((tree, tree));
 extern void finish_switch_stmt                  PROTO((tree, tree));
 extern void finish_case_label                   PROTO((tree, tree));
 extern void finish_goto_stmt                    PROTO((tree));
 extern tree begin_try_block                     PROTO((void));
 extern void finish_try_block                    PROTO((tree));
 extern void finish_handler_sequence             PROTO((tree));
+extern tree begin_function_try_block            PROTO((void));
+extern void finish_function_try_block           PROTO((tree));
+extern void finish_function_handler_sequence    PROTO((tree));
+extern void finish_cleanup_try_block            PROTO((tree));
 extern tree begin_handler                       PROTO((void));
-extern void finish_handler_parms                PROTO((tree));
-extern void finish_handler                      PROTO((tree));
+extern tree finish_handler_parms                PROTO((tree, tree));
+extern void begin_catch_block                   PROTO((tree));
+extern void finish_handler                      PROTO((tree, tree));
+extern void finish_cleanup                      PROTO((tree, tree));
 extern tree begin_compound_stmt                 PROTO((int));
 extern tree finish_compound_stmt                PROTO((int, tree));
 extern void finish_asm_stmt                     PROTO((tree, tree, tree, tree, tree));
+extern void finish_label_stmt                   PROTO((tree));
+extern void finish_label_decl                   PROTO((tree));
+extern void finish_subobject                    PROTO((tree));
 extern tree finish_parenthesized_expr           PROTO((tree));
 extern tree begin_stmt_expr                     PROTO((void));
-extern tree finish_stmt_expr                    PROTO((tree, tree));
+extern tree finish_stmt_expr                    PROTO((tree));
 extern tree finish_call_expr                    PROTO((tree, tree, int));
 extern tree finish_increment_expr               PROTO((tree, enum tree_code));
 extern tree finish_this_expr                    PROTO((void));
@@ -3336,8 +3892,6 @@ extern tree finish_qualified_call_expr          PROTO ((tree, tree));
 extern tree finish_label_address_expr           PROTO((tree));
 extern tree finish_unary_op_expr                PROTO((enum tree_code, tree));
 extern tree finish_id_expr                      PROTO((tree));
-extern int  begin_new_placement                 PROTO((void));
-extern tree finish_new_placement                PROTO((tree, int));
 extern int begin_function_definition            PROTO((tree, tree));
 extern tree begin_constructor_declarator        PROTO((tree, tree));
 extern tree finish_declarator                   PROTO((tree, tree, tree, tree, int));
@@ -3354,18 +3908,24 @@ extern tree finish_member_class_template        PROTO((tree));
 extern void finish_template_decl                PROTO((tree));
 extern tree finish_template_type                PROTO((tree, tree, int));
 extern void enter_scope_of                      PROTO((tree));
-extern tree finish_base_specifier               PROTO((tree, tree, int));
+extern tree finish_base_specifier               PROTO((tree, tree));
 extern void finish_member_declaration           PROTO((tree));
 extern void check_multiple_declarators          PROTO((void));
 extern tree finish_typeof                      PROTO((tree));
-
-/* in sig.c */
-extern tree build_signature_pointer_type       PROTO((tree));
-extern tree build_signature_reference_type     PROTO((tree));
-extern tree build_signature_pointer_constructor        PROTO((tree, tree));
-extern tree build_signature_method_call                PROTO((tree, tree));
-extern tree build_optr_ref                     PROTO((tree));
-extern void append_signature_fields            PROTO((tree));
+extern void add_decl_stmt                       PROTO((tree));
+extern void finish_decl_cleanup                 PROTO((tree, tree));
+extern void finish_named_return_value           PROTO((tree, tree));
+extern tree expand_stmt                         PROTO((tree));
+extern void expand_body                         PROTO((tree));
+extern void begin_stmt_tree                     PROTO((tree *));
+extern void finish_stmt_tree                    PROTO((tree *));
+extern void prep_stmt                           PROTO((tree));
+extern void add_scope_stmt                      PROTO((int, int));
+extern void do_pushlevel                        PROTO((void));
+extern tree do_poplevel                         PROTO((void));
+/* Non-zero if we are presently building a statement tree, rather
+   than expanding each statement as we encounter it.  */
+#define building_stmt_tree() (last_tree != NULL_TREE)
 
 /* in spew.c */
 extern void init_spew                          PROTO((void));
@@ -3374,6 +3934,8 @@ extern int yylex                          PROTO((void));
 extern tree arbitrate_lookup                   PROTO((tree, tree, tree));
 
 /* in tree.c */
+extern void init_tree                          PROTO((void));
+extern void cplus_unsave_expr_now               PROTO((tree));
 extern int pod_type_p                          PROTO((tree));
 extern void unshare_base_binfos                        PROTO((tree));
 extern int member_p                            PROTO((tree));
@@ -3402,7 +3964,6 @@ extern tree reverse_path                  PROTO((tree));
 extern int count_functions                     PROTO((tree));
 extern int is_overloaded_fn                    PROTO((tree));
 extern tree get_first_fn                       PROTO((tree));
-extern tree binding_init                        PROTO((struct tree_binding*));
 extern int bound_pmf_p                         PROTO((tree));
 extern tree ovl_cons                            PROTO((tree, tree));
 extern tree scratch_ovl_cons                    PROTO((tree, tree));
@@ -3412,11 +3973,9 @@ extern tree fnaddr_from_vtable_entry             PROTO((tree));
 extern tree function_arg_chain                 PROTO((tree));
 extern int promotes_to_aggr_type               PROTO((tree, enum tree_code));
 extern int is_aggr_type_2                      PROTO((tree, tree));
-extern char *lang_printable_name               PROTO((tree, int));
+extern const char *lang_printable_name         PROTO((tree, int));
 extern tree build_exception_variant            PROTO((tree, tree));
 extern tree copy_template_template_parm                PROTO((tree));
-extern tree copy_to_permanent                  PROTO((tree));
-extern tree permanent_p                         PROTO((tree));
 extern void print_lang_statistics              PROTO((void));
 extern void __eprintf
        PROTO((const char *, const char *, unsigned, const char *));
@@ -3429,7 +3988,6 @@ extern tree hack_decl_function_context            PROTO((tree));
 extern tree decl_namespace_context             PROTO((tree));
 extern tree lvalue_type                                PROTO((tree));
 extern tree error_type                         PROTO((tree));
-extern tree make_temp_vec                      PROTO((int));
 extern tree build_ptr_wrapper                  PROTO((void *));
 extern tree build_expr_ptr_wrapper             PROTO((void *));
 extern tree build_int_wrapper                  PROTO((int));
@@ -3438,14 +3996,15 @@ extern int varargs_function_p                   PROTO((tree));
 extern int really_overloaded_fn                        PROTO((tree));
 extern int cp_tree_equal                       PROTO((tree, tree));
 extern int can_free                            PROTO((struct obstack *, tree));
-extern tree mapcar                             PROTO((tree, tree (*) (tree)));
 extern tree no_linkage_check                   PROTO((tree));
 extern void debug_binfo                                PROTO((tree));
 extern void push_expression_obstack            PROTO((void));
+extern void push_permanent_obstack              PROTO((void));
 extern tree build_dummy_object                 PROTO((tree));
 extern tree maybe_dummy_object                 PROTO((tree, tree *));
 extern int is_dummy_object                     PROTO((tree));
-extern tree search_tree                         PROTO((tree, tree (*)(tree)));
+typedef tree (*walk_tree_fn)                    PROTO((tree *, int *, void *));
+extern tree walk_tree                           PROTO((tree *, walk_tree_fn, void *));
 extern int cp_valid_lang_attribute             PROTO((tree, tree, tree, tree));
 extern tree make_ptrmem_cst                     PROTO((tree, tree));
 extern tree cp_build_qualified_type_real        PROTO((tree, int, int));
@@ -3453,9 +4012,7 @@ extern tree cp_build_qualified_type_real        PROTO((tree, int, int));
   cp_build_qualified_type_real ((TYPE), (QUALS), /*complain=*/1)
 
 #define scratchalloc expralloc
-#define scratch_tree_cons expr_tree_cons
 #define build_scratch_list build_expr_list
-#define make_scratch_vec make_temp_vec
 #define push_scratch_obstack push_expression_obstack
 
 /* in typeck.c */
@@ -3463,7 +4020,6 @@ extern int string_conv_p                  PROTO((tree, tree, int));
 extern tree condition_conversion               PROTO((tree));
 extern tree target_type                                PROTO((tree));
 extern tree require_complete_type              PROTO((tree));
-extern tree require_complete_type_in_void      PROTO((tree));
 extern tree complete_type                      PROTO((tree));
 extern tree complete_type_or_else               PROTO((tree, tree));
 extern int type_unknown_p                      PROTO((tree));
@@ -3471,14 +4027,13 @@ extern int fntype_p                             PROTO((tree));
 extern tree commonparms                                PROTO((tree, tree));
 extern tree original_type                      PROTO((tree));
 extern tree common_type                                PROTO((tree, tree));
-extern int compexcepttypes                     PROTO((tree, tree));
+extern int comp_except_specs                   PROTO((tree, tree, int));
 extern int comptypes                           PROTO((tree, tree, int));
 extern int comp_target_types                   PROTO((tree, tree, int));
 extern int compparms                           PROTO((tree, tree));
 extern int comp_target_types                   PROTO((tree, tree, int));
 extern int comp_cv_qualification                PROTO((tree, tree));
 extern int comp_cv_qual_signature               PROTO((tree, tree));
-extern int self_promoting_args_p               PROTO((tree));
 extern tree unsigned_type                      PROTO((tree));
 extern tree signed_type                                PROTO((tree));
 extern tree signed_or_unsigned_type            PROTO((int, tree));
@@ -3526,6 +4081,7 @@ extern tree c_expand_start_case                   PROTO((tree));
 extern int comp_ptr_ttypes                     PROTO((tree, tree));
 extern int ptr_reasonably_similar              PROTO((tree, tree));
 extern tree build_ptrmemfunc                   PROTO((tree, tree, int));
+extern tree strip_array_types                   PROTO((tree));
 extern int cp_type_quals                        PROTO((tree));
 extern int cp_has_mutable_p                     PROTO((tree));
 extern int at_least_as_qualified_p              PROTO((tree, tree));
@@ -3534,13 +4090,16 @@ extern tree build_ptrmemfunc1                   PROTO((tree, tree, tree, tree, t
 extern void expand_ptrmemfunc_cst               PROTO((tree, tree *, tree *, tree *, tree *));
 extern tree delta2_from_ptrmemfunc              PROTO((tree));
 extern tree pfn_from_ptrmemfunc                 PROTO((tree));
+extern tree type_after_usual_arithmetic_conversions PROTO((tree, tree));
+extern tree composite_pointer_type              PROTO((tree, tree, tree, tree,
+                                                      const char*));
+extern tree check_return_expr                   PROTO((tree));
 
 /* in typeck2.c */
 extern tree error_not_base_type                        PROTO((tree, tree));
 extern tree binfo_or_else                      PROTO((tree, tree));
 extern void readonly_error                     PROTO((tree, const char *, int));
-extern void abstract_virtuals_error            PROTO((tree, tree));
-extern void signature_error                    PROTO((tree, tree));
+extern int abstract_virtuals_error             PROTO((tree, tree));
 extern void incomplete_type_error              PROTO((tree, tree));
 extern void my_friendly_abort                  PROTO((int))
   ATTRIBUTE_NORETURN;
@@ -3554,7 +4113,7 @@ extern tree build_functional_cast         PROTO((tree, tree));
 extern char *enum_name_string                  PROTO((tree, tree));
 extern void report_case_error                  PROTO((int, tree, tree, tree));
 extern void check_for_new_type                 PROTO((const char *, flagged_type_tree));
-extern tree initializer_constant_valid_p       PROTO((tree, tree));
+extern tree add_exception_specifier             PROTO((tree, tree, int));
 
 /* in xref.c */
 extern void GNU_xref_begin                     PROTO((const char *));
@@ -3570,6 +4129,9 @@ extern void GNU_xref_assign                       PROTO((tree));
 extern void GNU_xref_hier                      PROTO((tree, tree, int, int, int));
 extern void GNU_xref_member                    PROTO((tree, tree));
 
+/* in dump.c */
+extern void dump_node_to_file                   PROTO ((tree, const char *));
+
 /* -- end of C++ */
 
 #endif /* not _CP_TREE_H */