diff options
author | Nathan Sidwell <nathan@gcc.gnu.org> | 2004-07-09 18:36:02 +0000 |
---|---|---|
committer | Nathan Sidwell <nathan@gcc.gnu.org> | 2004-07-09 18:36:02 +0000 |
commit | 85fd2947bd37c39eb2b8b237359743ae0ecbb657 (patch) | |
tree | b87da749b2399f55835e9ab316900e5ad252f294 /gcc/java/class.c | |
parent | 6512c54ac4e97aa257dce77ef5fea177dee46e42 (diff) | |
download | gcc-85fd2947bd37c39eb2b8b237359743ae0ecbb657.zip gcc-85fd2947bd37c39eb2b8b237359743ae0ecbb657.tar.gz gcc-85fd2947bd37c39eb2b8b237359743ae0ecbb657.tar.bz2 |
class.c (make_class): Do not create binfo here.
* class.c (make_class): Do not create binfo here.
(set_super_info): Create it here.
* java-tree.h (CLASS_HAS_SUPER): Cope with lack of a binfo.
From-SVN: r84388
Diffstat (limited to 'gcc/java/class.c')
-rw-r--r-- | gcc/java/class.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gcc/java/class.c b/gcc/java/class.c index 5e7c2b9..c09e2e5 100644 --- a/gcc/java/class.c +++ b/gcc/java/class.c @@ -318,7 +318,6 @@ make_class (void) { tree type; type = make_node (RECORD_TYPE); - TYPE_BINFO (type) = make_tree_binfo (0); MAYBE_CREATE_TYPE_TYPE_LANG_SPECIFIC (type); return type; @@ -473,9 +472,11 @@ set_super_info (int access_flags, tree this_class, { int total_supers = interfaces_count; tree class_decl = TYPE_NAME (this_class); + if (super_class) total_supers++; + TYPE_BINFO (this_class) = make_tree_binfo (0); TYPE_VFIELD (this_class) = TYPE_VFIELD (object_type_node); BINFO_BASE_BINFOS (TYPE_BINFO (this_class)) = make_tree_vec (total_supers); if (super_class) @@ -485,7 +486,7 @@ set_super_info (int access_flags, tree this_class, BINFO_OFFSET (super_binfo) = integer_zero_node; TREE_VEC_ELT (BINFO_BASE_BINFOS (TYPE_BINFO (this_class)), 0) = super_binfo; - CLASS_HAS_SUPER (this_class) = 1; + CLASS_HAS_SUPER_FLAG (TYPE_BINFO (this_class)) = 1; } set_class_decl_access_flags (access_flags, class_decl); |