Bug 769871 - Remove x_CheckThisX methods, as the extract-the-primitive-value methods immediately after perform that check already. r=Norbert

This commit is contained in:
Jeff Walden
2013-03-22 12:35:44 -07:00
parent 93685efc00
commit b88dba376a
7 changed files with 6 additions and 76 deletions

View File

@@ -1392,26 +1392,6 @@ IsDate(const Value &v)
return v.isObject() && v.toObject().hasClass(&DateClass);
}
JS_ALWAYS_INLINE bool
date_nop(JSContext *cx, CallArgs args)
{
JS_ASSERT(IsDate(args.thisv()));
args.rval().setUndefined();
return true;
}
JSBool
date_CheckThisDate(JSContext *cx, unsigned argc, Value *vp)
{
CallArgs args = CallArgsFromVp(argc, vp);
// CallNonGenericMethod will handle proxies correctly and throw exceptions
// in the right circumstances, but will report date_CheckThisDate as the
// function name in the message. We need a better solution:
// https://bugzilla.mozilla.org/show_bug.cgi?id=844677
return CallNonGenericMethod<IsDate, date_nop>(cx, args);
}
/*
* See ECMA 15.9.5.4 thru 15.9.5.23
*/