Bug 610480 part 3: silence a last few MSVC warnings

This commit is contained in:
David Mandelin 2010-11-11 12:17:08 -08:00
parent f6824293ac
commit 1d9fdc0aba
2 changed files with 8 additions and 4 deletions

View File

@ -921,11 +921,13 @@ JSObject::putProperty(JSContext *cx, jsid id,
}
}
JS_ASSERT(uint8(attrs) == attrs);
JS_ASSERT(int16(shortid) == shortid);
shape->rawGetter = getter;
shape->rawSetter = setter;
shape->attrs = attrs;
shape->attrs = uint8(attrs);
shape->flags = flags | Shape::IN_DICTIONARY;
shape->shortid = shortid;
shape->shortid = int16(shortid);
/*
* We are done updating shape and lastProp. Now we may need to update

View File

@ -1037,8 +1037,10 @@ JSScript::NewScript(JSContext *cx, uint32 length, uint32 nsrcnotes, uint32 natom
}
if (totalClosed != 0) {
script->nClosedArgs = nClosedArgs;
script->nClosedVars = nClosedVars;
JS_ASSERT(uint16(nClosedArgs) == nClosedArgs);
JS_ASSERT(uint16(nClosedVars) == nClosedVars);
script->nClosedArgs = uint16(nClosedArgs);
script->nClosedVars = uint16(nClosedVars);
script->closedSlots = (uint32 *)cursor;
cursor += totalClosed * sizeof(uint32);
}