mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Fix incompatible enum warnings in static asserts
This commit is contained in:
parent
cfb0d1fd1b
commit
9e09ec6424
@ -515,9 +515,9 @@ static inline JSTraceType getPromotedType(jsval v)
|
||||
}
|
||||
uint8_t tag = JSVAL_TAG(v);
|
||||
JS_ASSERT(tag == JSVAL_DOUBLE || tag == JSVAL_STRING || tag == JSVAL_BOOLEAN);
|
||||
JS_STATIC_ASSERT(TT_DOUBLE == JSVAL_DOUBLE);
|
||||
JS_STATIC_ASSERT(TT_STRING == JSVAL_STRING);
|
||||
JS_STATIC_ASSERT(TT_PSEUDOBOOLEAN == JSVAL_BOOLEAN);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_DOUBLE) == JSVAL_DOUBLE);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_STRING) == JSVAL_STRING);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_PSEUDOBOOLEAN) == JSVAL_BOOLEAN);
|
||||
return JSTraceType(tag);
|
||||
}
|
||||
|
||||
@ -535,9 +535,9 @@ static inline JSTraceType getCoercedType(jsval v)
|
||||
}
|
||||
uint8_t tag = JSVAL_TAG(v);
|
||||
JS_ASSERT(tag == JSVAL_DOUBLE || tag == JSVAL_STRING || tag == JSVAL_BOOLEAN);
|
||||
JS_STATIC_ASSERT(TT_DOUBLE == JSVAL_DOUBLE);
|
||||
JS_STATIC_ASSERT(TT_STRING == JSVAL_STRING);
|
||||
JS_STATIC_ASSERT(TT_PSEUDOBOOLEAN == JSVAL_BOOLEAN);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_DOUBLE) == JSVAL_DOUBLE);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_STRING) == JSVAL_STRING);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_PSEUDOBOOLEAN) == JSVAL_BOOLEAN);
|
||||
return JSTraceType(tag);
|
||||
}
|
||||
|
||||
@ -2895,8 +2895,8 @@ TraceRecorder::determineSlotType(jsval* vp)
|
||||
m = TT_OBJECT;
|
||||
} else {
|
||||
JS_ASSERT(JSVAL_TAG(*vp) == JSVAL_STRING || JSVAL_TAG(*vp) == JSVAL_BOOLEAN);
|
||||
JS_STATIC_ASSERT(TT_STRING == JSVAL_STRING);
|
||||
JS_STATIC_ASSERT(TT_PSEUDOBOOLEAN == JSVAL_BOOLEAN);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_STRING) == JSVAL_STRING);
|
||||
JS_STATIC_ASSERT(static_cast<jsvaltag>(TT_PSEUDOBOOLEAN) == JSVAL_BOOLEAN);
|
||||
m = JSTraceType(JSVAL_TAG(*vp));
|
||||
}
|
||||
JS_ASSERT(m != TT_INT32 || isInt32(*vp));
|
||||
|
Loading…
Reference in New Issue
Block a user