summaryrefslogtreecommitdiffstats
path: root/gcc/java/parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/java/parse.y')
-rw-r--r--gcc/java/parse.y5
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/java/parse.y b/gcc/java/parse.y
index 0649dbe6de1..3212ddaf078 100644
--- a/gcc/java/parse.y
+++ b/gcc/java/parse.y
@@ -4037,6 +4037,11 @@ create_class (int flags, tree id, tree super, tree interfaces)
CLASS_COMPLETE_P (decl) = 1;
add_superinterfaces (decl, interfaces);
+ /* TYPE_VFIELD' is a compiler-generated field used to point to
+ virtual function tables. In gcj, every class has a common base
+ virtual function table in java.lang.object. */
+ TYPE_VFIELD (TREE_TYPE (decl)) = TYPE_VFIELD (object_type_node);
+
/* Add the private this$<n> field, Replicate final locals still in
scope as private final fields mangled like val$<local_name>.
This doesn't not occur for top level (static) inner classes. */
OpenPOWER on IntegriCloud