Generate GetConstructorObject for all interfaces

This commit is contained in:
Connor Brewster 2017-06-12 21:50:53 -06:00
parent 147dfcc99b
commit 0713257add
2 changed files with 6 additions and 2 deletions

View file

@ -2863,7 +2863,7 @@ create_noncallback_interface_object(cx,
%(length)s,
interface.handle_mut());
assert!(!interface.is_null());""" % properties))
if self.descriptor.hasDescendants():
if self.descriptor.shouldCacheConstructor():
code.append(CGGeneric("""\
assert!((*cache)[PrototypeList::Constructor::%(id)s as usize].is_null());
(*cache)[PrototypeList::Constructor::%(id)s as usize] = interface.get();