aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/cp')
-rw-r--r--gcc/cp/ChangeLog10
-rw-r--r--gcc/cp/cp-lang.c8
-rw-r--r--gcc/cp/cp-tree.h2
-rw-r--r--gcc/cp/decl.c4
-rw-r--r--gcc/cp/tree.c2
5 files changed, 20 insertions, 6 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 0b94657..39b60eb 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,13 @@
+2002-04-24 Neil Booth <neil@daikokuya.demon.co.uk>
+
+ * cp-lang.c (LANG_HOOKS_COMMON_ATTRIBUTE_TABLE,
+ LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE, LANG_HOOKS_ATTRIBUTE_TABLE):
+ Redefine.
+ * cp-tree.h (cp_attribute_table): Rename.
+ * decl.c (lang_attribute_table): Remove declaration.
+ (cxx_init_decl_processing): Don't set it.
+ * tree.c (cp_attribute_table): Rename.
+
2002-04-24 Jason Merrill <jason@redhat.com>
PR c++/6331
diff --git a/gcc/cp/cp-lang.c b/gcc/cp/cp-lang.c
index 0cca267..3a8417d 100644
--- a/gcc/cp/cp-lang.c
+++ b/gcc/cp/cp-lang.c
@@ -100,6 +100,14 @@ static bool cxx_warn_unused_global_decl PARAMS ((tree));
#undef LANG_HOOKS_FUNCTION_MARK
#define LANG_HOOKS_FUNCTION_MARK cxx_mark_function_context
+/* Attribute hooks. */
+#undef LANG_HOOKS_COMMON_ATTRIBUTE_TABLE
+#define LANG_HOOKS_COMMON_ATTRIBUTE_TABLE c_common_attribute_table
+#undef LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE
+#define LANG_HOOKS_FORMAT_ATTRIBUTE_TABLE c_common_format_attribute_table
+#undef LANG_HOOKS_ATTRIBUTE_TABLE
+#define LANG_HOOKS_ATTRIBUTE_TABLE cxx_attribute_table
+
#undef LANG_HOOKS_TREE_INLINING_WALK_SUBTREES
#define LANG_HOOKS_TREE_INLINING_WALK_SUBTREES \
cp_walk_subtrees
diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h
index bdc4b4f..a692c98 100644
--- a/gcc/cp/cp-tree.h
+++ b/gcc/cp/cp-tree.h
@@ -4287,7 +4287,7 @@ extern void debug_binfo PARAMS ((tree));
extern tree build_dummy_object PARAMS ((tree));
extern tree maybe_dummy_object PARAMS ((tree, tree *));
extern int is_dummy_object PARAMS ((tree));
-extern const struct attribute_spec cp_attribute_table[];
+extern const struct attribute_spec cxx_attribute_table[];
extern tree make_ptrmem_cst PARAMS ((tree, tree));
extern tree cp_build_qualified_type_real PARAMS ((tree, int, tsubst_flags_t));
#define cp_build_qualified_type(TYPE, QUALS) \
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index fe3b4a5..a260e11 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -49,8 +49,6 @@ Boston, MA 02111-1307, USA. */
#include "c-pragma.h"
#include "diagnostic.h"
-extern const struct attribute_spec *lang_attribute_table;
-
#ifndef BOOL_TYPE_SIZE
/* `bool' has size and alignment `1', on all platforms. */
#define BOOL_TYPE_SIZE CHAR_TYPE_SIZE
@@ -6531,8 +6529,6 @@ cxx_init_decl_processing ()
std_node = current_namespace;
pop_namespace ();
- lang_attribute_table = cp_attribute_table;
-
c_common_nodes_and_builtins ();
java_byte_type_node = record_builtin_java_type ("__java_byte", 8);
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index 641d82b..ff3e633 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -1895,7 +1895,7 @@ pod_type_p (t)
}
/* Table of valid C++ attributes. */
-const struct attribute_spec cp_attribute_table[] =
+const struct attribute_spec cxx_attribute_table[] =
{
/* { name, min_len, max_len, decl_req, type_req, fn_type_req, handler } */
{ "java_interface", 0, 0, false, false, false, handle_java_interface_attribute },