diff options
author | Nick Fitzgerald <fitzgen@gmail.com> | 2017-10-13 14:17:26 -0700 |
---|---|---|
committer | Nick Fitzgerald <fitzgen@gmail.com> | 2017-10-23 09:43:51 -0700 |
commit | 02dc02ba648e527559bc1e53b0f7554b584cf1f4 (patch) | |
tree | 35083783b02cf3dd644d91b3472387ca92e876ba /src/codegen/mod.rs | |
parent | b59ffb8456a2629fcb40a8cd92097226f98f4828 (diff) |
Remove `CompInfo::needs_explicit_vtable` and use `HasVtable::has_vtable_ptr` instead
Diffstat (limited to 'src/codegen/mod.rs')
-rw-r--r-- | src/codegen/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/codegen/mod.rs b/src/codegen/mod.rs index ac28244c..6396e953 100644 --- a/src/codegen/mod.rs +++ b/src/codegen/mod.rs @@ -1424,7 +1424,7 @@ impl CodeGenerator for CompInfo { // // FIXME: Once we generate proper vtables, we need to codegen the // vtable, but *not* generate a field for it in the case that - // needs_explicit_vtable is false but has_vtable is true. + // HasVtable::has_vtable_ptr is false but HasVtable::has_vtable is true. // // Also, we need to generate the vtable in such a way it "inherits" from // the parent too. @@ -1434,7 +1434,7 @@ impl CodeGenerator for CompInfo { StructLayoutTracker::new(ctx, self, &canonical_name); if !is_opaque { - if self.needs_explicit_vtable(ctx, item) { + if item.has_vtable_ptr(ctx) { let vtable = Vtable::new(item.id(), self.methods(), self.base_members()); vtable.codegen(ctx, result, item); |