зеркало из https://github.com/mozilla/gecko-dev.git
Fix warnings flagged by the auto-warnings page http://tinderbox.mozilla.org/SeaMonkey/warnings.html . Thanks slamm.
This commit is contained in:
Родитель
db0c8b521d
Коммит
5bfae9e201
|
@ -1424,9 +1424,9 @@ date_toGMTString(JSContext *cx, JSObject *obj, uintN argc,
|
|||
* that's in range.
|
||||
*/
|
||||
static void
|
||||
new_explode(jsdouble time, PRMJTime *split, JSBool findEquivalent)
|
||||
new_explode(jsdouble timeval, PRMJTime *split, JSBool findEquivalent)
|
||||
{
|
||||
jsint year = YearFromTime(time);
|
||||
jsint year = YearFromTime(timeval);
|
||||
int16 adjustedYear;
|
||||
|
||||
/* If the year doesn't fit in a PRMJTime, find something to do about it. */
|
||||
|
@ -1449,19 +1449,19 @@ new_explode(jsdouble time, PRMJTime *split, JSBool findEquivalent)
|
|||
adjustedYear = (int16)year;
|
||||
}
|
||||
|
||||
split->tm_usec = (int32) msFromTime(time) * 1000;
|
||||
split->tm_sec = (int8) SecFromTime(time);
|
||||
split->tm_min = (int8) MinFromTime(time);
|
||||
split->tm_hour = (int8) HourFromTime(time);
|
||||
split->tm_mday = (int8) DateFromTime(time);
|
||||
split->tm_mon = (int8) MonthFromTime(time);
|
||||
split->tm_wday = (int8) WeekDay(time);
|
||||
split->tm_usec = (int32) msFromTime(timeval) * 1000;
|
||||
split->tm_sec = (int8) SecFromTime(timeval);
|
||||
split->tm_min = (int8) MinFromTime(timeval);
|
||||
split->tm_hour = (int8) HourFromTime(timeval);
|
||||
split->tm_mday = (int8) DateFromTime(timeval);
|
||||
split->tm_mon = (int8) MonthFromTime(timeval);
|
||||
split->tm_wday = (int8) WeekDay(timeval);
|
||||
split->tm_year = (int16) adjustedYear;
|
||||
split->tm_yday = (int16) DayWithinYear(time, year);
|
||||
split->tm_yday = (int16) DayWithinYear(timeval, year);
|
||||
|
||||
/* not sure how this affects things, but it doesn't seem
|
||||
to matter. */
|
||||
split->tm_isdst = (DaylightSavingTA(time) != 0);
|
||||
split->tm_isdst = (DaylightSavingTA(timeval) != 0);
|
||||
}
|
||||
|
||||
/* helper function */
|
||||
|
|
|
@ -1702,7 +1702,7 @@ js_EmitTree(JSContext *cx, JSCodeGenerator *cg, JSParseNode *pn)
|
|||
*/
|
||||
pn2 = pn->pn_left;
|
||||
JS_ASSERT(pn2->pn_type != TOK_RP);
|
||||
atomIndex = -1;
|
||||
atomIndex = (jsatomid) -1; /* Suppress warning. */
|
||||
switch (pn2->pn_type) {
|
||||
case TOK_NAME:
|
||||
if (pn2->pn_slot >= 0) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче