JS_ReportError(cx, "%s has no constructor",
JS_ReportErrorNumber(cx, NULL, JSMSG_NO_CONSTRUCTOR,
JS_GetConstructor(JSContext *cx, JSObject *proto){    JSBool ok;    jsval cval;    CHECK_REQUEST(cx);    ok = OBJ_GET_PROPERTY(cx, proto,			  (jsid)cx->runtime->atomState.constructorAtom,			  &cval);    if (!ok)	return NULL;    if (!JSVAL_IS_FUNCTION(cx, cval)) {	JS_ReportError(cx, "%s has no constructor",		       OBJ_GET_CLASS(cx, proto)->name);	return NULL;    }    return JSVAL_TO_OBJECT(cval);}