mirror of
https://github.com/Eaglercraft-TeaVM-Fork/eagler-teavm.git
synced 2024-12-22 08:14:09 -08:00
C: fix virtual tables
This commit is contained in:
parent
f5c2cf0fa3
commit
816434500c
|
@ -107,9 +107,12 @@ public class VirtualTableProvider {
|
|||
|
||||
private void copyEntriesFromSupertype(VirtualTable table, VirtualTable supertypeTable) {
|
||||
for (VirtualTableEntry parentEntry : supertypeTable.entries.values()) {
|
||||
VirtualTableEntry entry = new VirtualTableEntry(table, parentEntry.getMethod(),
|
||||
parentEntry.getImplementor(), parentEntry.getIndex());
|
||||
table.entries.put(entry.getMethod(), entry);
|
||||
VirtualTableEntry existingEntry = table.entries.get(parentEntry.getMethod());
|
||||
if (existingEntry == null || existingEntry.getImplementor() == null) {
|
||||
VirtualTableEntry entry = new VirtualTableEntry(table, parentEntry.getMethod(),
|
||||
parentEntry.getImplementor(), parentEntry.getIndex());
|
||||
table.entries.put(entry.getMethod(), entry);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user