diff options
author | Paul Brook <pbrook@gcc.gnu.org> | 2004-09-02 19:32:57 +0000 |
---|---|---|
committer | Paul Brook <pbrook@gcc.gnu.org> | 2004-09-02 19:32:57 +0000 |
commit | 96f629573dc5831580c97141a9ac37a624f71b9a (patch) | |
tree | 606a429b08da4e9c0707c5913f9980a5f87f5c62 | |
parent | 6cbc6f0db154b001895740d108b56558fe4761b9 (diff) | |
download | gcc-96f629573dc5831580c97141a9ac37a624f71b9a.zip gcc-96f629573dc5831580c97141a9ac37a624f71b9a.tar.gz gcc-96f629573dc5831580c97141a9ac37a624f71b9a.tar.bz2 |
decl2.c (determine_visibility): Only check data visibility for VAR_DECLS.
* decl2.c (determine_visibility): Only check data visibility
for VAR_DECLS.
[[Split portion of a mixed commit.]]
From-SVN: r86983.2
-rw-r--r-- | gcc/cp/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/cp/decl2.c | 3 |
2 files changed, 8 insertions, 2 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 929bde0..14dac82 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,8 @@ +2004-09-02 Paul Brook <paul@codesourcery.com> + + * decl2.c (determine_visibility): Only check data visibility + for VAR_DECLS. + 2004-08-31 Mark Mitchell <mark@codesourcery.com> * cp-tree.h (DECL_CONSTRUCTION_VTABLE_P): New macro. @@ -5,7 +10,7 @@ * decl2.c (determine_visibility): Honor TARGET_CXX_EXPORT_CLASS_DATA. - * class.c (key_method): Rename to ... + * class.c (key_method): Rename to ... (determine_key_method): ... this. (finish_struct_1): Adjust accordingly. * cp-tree.h (key_method): Declare. diff --git a/gcc/cp/decl2.c b/gcc/cp/decl2.c index c26d48f..03c468d 100644 --- a/gcc/cp/decl2.c +++ b/gcc/cp/decl2.c @@ -1655,7 +1655,8 @@ determine_visibility (tree decl) the visibility of their containing class. */ if (class_type) { - if (targetm.cxx.export_class_data () + if (TREE_CODE (decl) == VAR_DECL + && targetm.cxx.export_class_data () && (DECL_TINFO_P (decl) || (DECL_VTABLE_OR_VTT_P (decl) /* Construction virtual tables are not emitted |