Bug 790349 - Convert all fooAtom uses to simply foo. r=jorendorff
This commit is contained in:
@@ -2609,7 +2609,7 @@ date_toJSON(JSContext *cx, unsigned argc, Value *vp)
|
||||
|
||||
/* Step 4. */
|
||||
RootedValue toISO(cx);
|
||||
if (!JSObject::getProperty(cx, obj, obj, cx->runtime->atomState.toISOStringAtom, &toISO))
|
||||
if (!JSObject::getProperty(cx, obj, obj, cx->names().toISOString, &toISO))
|
||||
return false;
|
||||
|
||||
/* Step 5. */
|
||||
@@ -3161,7 +3161,7 @@ js_InitDateClass(JSContext *cx, JSObject *obj)
|
||||
SetDateToNaN(cx, dateProto);
|
||||
|
||||
RootedFunction ctor(cx);
|
||||
ctor = global->createConstructor(cx, js_Date, cx->runtime->atomState.DateAtom, MAXARGS);
|
||||
ctor = global->createConstructor(cx, js_Date, cx->names().Date, MAXARGS);
|
||||
if (!ctor)
|
||||
return NULL;
|
||||
|
||||
@@ -3179,8 +3179,8 @@ js_InitDateClass(JSContext *cx, JSObject *obj)
|
||||
if (!JS_DefineFunctions(cx, dateProto, date_methods))
|
||||
return NULL;
|
||||
RootedValue toUTCStringFun(cx);
|
||||
RootedId toUTCStringId(cx, NameToId(cx->runtime->atomState.toUTCStringAtom));
|
||||
RootedId toGMTStringId(cx, NameToId(cx->runtime->atomState.toGMTStringAtom));
|
||||
RootedId toUTCStringId(cx, NameToId(cx->names().toUTCString));
|
||||
RootedId toGMTStringId(cx, NameToId(cx->names().toGMTString));
|
||||
if (!baseops::GetProperty(cx, dateProto, toUTCStringId, &toUTCStringFun) ||
|
||||
!baseops::DefineGeneric(cx, dateProto, toGMTStringId, toUTCStringFun,
|
||||
JS_PropertyStub, JS_StrictPropertyStub, 0))
|
||||
|
||||
Reference in New Issue
Block a user