mirror of
https://github.com/bellard/quickjs.git
synced 2024-11-22 21:58:12 +08:00
Fix
This commit is contained in:
parent
b0c2d79fd4
commit
a1f74f9f22
12
quickjs.h
12
quickjs.h
@ -93,6 +93,12 @@ typedef struct JSRefCountHeader {
|
|||||||
|
|
||||||
#define JS_FLOAT64_NAN NAN
|
#define JS_FLOAT64_NAN NAN
|
||||||
|
|
||||||
|
#if defined(_MSC_VER)
|
||||||
|
#define JS_VALUE_CAST(t, v) v
|
||||||
|
#else
|
||||||
|
#define JS_VALUE_CAST(t, v) (t)v
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_CHECK_JSVALUE
|
#ifdef CONFIG_CHECK_JSVALUE
|
||||||
/* JSValue consistency : it is not possible to run the code in this
|
/* JSValue consistency : it is not possible to run the code in this
|
||||||
mode, but it is useful to detect simple reference counting
|
mode, but it is useful to detect simple reference counting
|
||||||
@ -207,12 +213,6 @@ typedef struct JSValue {
|
|||||||
|
|
||||||
#define JSValueConst JSValue
|
#define JSValueConst JSValue
|
||||||
|
|
||||||
#if defined(_MSC_VER)
|
|
||||||
#define JS_VALUE_CAST(t, v) v
|
|
||||||
#else
|
|
||||||
#define JS_VALUE_CAST(t, v) (t)v
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define JS_VALUE_GET_TAG(v) ((int32_t)(v).tag)
|
#define JS_VALUE_GET_TAG(v) ((int32_t)(v).tag)
|
||||||
/* same as JS_VALUE_GET_TAG, but return JS_TAG_FLOAT64 with NaN boxing */
|
/* same as JS_VALUE_GET_TAG, but return JS_TAG_FLOAT64 with NaN boxing */
|
||||||
#define JS_VALUE_GET_NORM_TAG(v) JS_VALUE_GET_TAG(v)
|
#define JS_VALUE_GET_NORM_TAG(v) JS_VALUE_GET_TAG(v)
|
||||||
|
Loading…
Reference in New Issue
Block a user