Re: Object creation in SpiderMonkey 45
Mihai Dobrescu <[email protected]>
| Newsgroups | gmane.comp.mozilla.devel.jseng |
|---|---|
| Message-ID | <[email protected]> |
On Thursday, May 5, 2016 at 7:27:05 PM UTC+3, Boris Zbarsky wrote: > On 5/5/16 11:19 AM, Mihai Dobrescu wrote: > > JSObject *obj = JS_NewObject(cx, &jsDataClass<jsPropertyType>::fClass); > > Here's your problem. You didn't give it the right prototype. > > Things used to default to "if you pass no prototype and just the class > we'll do some fragile lookup to try to figure out the right prototype", > but that went away in https://bugzilla.mozilla.org/show_bug.cgi?id=1125567 > > So you need to pass in the right prototype object here. > > -Boris I don't understand what you mean. It is 45, not 38.