Ticket #3258: t3258_missing_script_conversions_for_windows_v1.patch
File t3258_missing_script_conversions_for_windows_v1.patch, 1.2 KB (added by , 9 years ago) |
---|
-
source/scriptinterface/ScriptConversions.cpp
template<> void ScriptInterface::ToJSVal 266 266 template<> void ScriptInterface::ToJSVal<unsigned long>(JSContext* UNUSED(cx), JS::MutableHandleValue ret, const unsigned long& val) 267 267 { 268 268 ret.set(JS::NumberValue((int)val)); 269 269 } 270 270 271 template<> void ScriptInterface::ToJSVal<time_t>(JSContext* UNUSED(cx), JS::MutableHandleValue ret, const time_t& val) 272 { 273 ret.set(JS::NumberValue((int)val)); 274 } 275 276 template<> void ScriptInterface::ToJSVal<u64>(JSContext* UNUSED(cx), JS::MutableHandleValue ret, const u64& val) 277 { 278 ret.set(JS::NumberValue((int)val)); 279 } 280 271 281 // (s)size_t are considered to be identical to (unsigned) int by GCC and 272 282 // their specializations would cause conflicts there. On x86_64 GCC, s/size_t 273 283 // is equivalent to (unsigned) long, but the same solution applies; use the 274 284 // long and unsigned long specializations instead of s/size_t. 275 285 // for some reason, x64 MSC treats size_t as distinct from unsigned long: