mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
No bug - Move the bool specialization of PrimitiveConversionTraits from between the integer ones.
This commit is contained in:
parent
bd32566761
commit
40c67660e9
@ -76,16 +76,6 @@ template<>
|
||||
struct PrimitiveConversionTraits<uint32_t> : PrimitiveConversionTraits_smallInt {
|
||||
};
|
||||
|
||||
template<>
|
||||
struct PrimitiveConversionTraits<bool> {
|
||||
typedef JSBool jstype;
|
||||
typedef bool intermediateType;
|
||||
static inline bool converter(JSContext* /* unused */, JS::Value v, jstype* retval) {
|
||||
*retval = JS::ToBoolean(v);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
template<>
|
||||
struct PrimitiveConversionTraits<int64_t> {
|
||||
typedef int64_t jstype;
|
||||
@ -104,6 +94,16 @@ struct PrimitiveConversionTraits<uint64_t> {
|
||||
}
|
||||
};
|
||||
|
||||
template<>
|
||||
struct PrimitiveConversionTraits<bool> {
|
||||
typedef JSBool jstype;
|
||||
typedef bool intermediateType;
|
||||
static inline bool converter(JSContext* /* unused */, JS::Value v, jstype* retval) {
|
||||
*retval = JS::ToBoolean(v);
|
||||
return true;
|
||||
}
|
||||
};
|
||||
|
||||
struct PrimitiveConversionTraits_float {
|
||||
typedef double jstype;
|
||||
typedef double intermediateType;
|
||||
|
Loading…
Reference in New Issue
Block a user