bool IndirectBindingMap::putNew(JSContext* cx, HandleId name, HandleModuleEnvironmentObject environment, HandleId localName) { RootedShape shape(cx, environment->lookup(cx, localName)); MOZ_ASSERT(shape); return map_.putNew(name, Binding(environment, shape)); }
bool IndirectBindingMap::putNew(JSContext* cx, HandleId name, HandleModuleEnvironmentObject environment, HandleId localName) { RootedShape shape(cx, environment->lookup(cx, localName)); MOZ_ASSERT(shape); if (!map_.putNew(name, Binding(environment, shape))) { ReportOutOfMemory(cx); return false; } return true; }