mirror of
https://github.com/bellard/quickjs.git
synced 2025-09-30 15:04:24 +03:00
more use of js_new_string8 - inlined JS_NewString() (initial patch by Charlie Gordon)
This commit is contained in:
@@ -715,7 +715,10 @@ int JS_ToBigInt64(JSContext *ctx, int64_t *pres, JSValueConst val);
|
||||
int JS_ToInt64Ext(JSContext *ctx, int64_t *pres, JSValueConst val);
|
||||
|
||||
JSValue JS_NewStringLen(JSContext *ctx, const char *str1, size_t len1);
|
||||
JSValue JS_NewString(JSContext *ctx, const char *str);
|
||||
static inline JSValue JS_NewString(JSContext *ctx, const char *str)
|
||||
{
|
||||
return JS_NewStringLen(ctx, str, strlen(str));
|
||||
}
|
||||
JSValue JS_NewAtomString(JSContext *ctx, const char *str);
|
||||
JSValue JS_ToString(JSContext *ctx, JSValueConst val);
|
||||
JSValue JS_ToPropertyKey(JSContext *ctx, JSValueConst val);
|
||||
|
Reference in New Issue
Block a user