diff options
author | bptato <nincsnevem662@gmail.com> | 2023-12-23 13:32:41 +0100 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2023-12-23 13:35:40 +0100 |
commit | f231ffeffb9bcbffde5429262a13dfad3ea89f5c (patch) | |
tree | bb7c1c5b912341cf93c9ba0103574cee651a58dc /src/js | |
parent | 1088cc3b01c0dacd4ce017803b89dc47fb55bee6 (diff) | |
download | chawan-f231ffeffb9bcbffde5429262a13dfad3ea89f5c.tar.gz |
bindings/quickjs: cint -> csize_t
cint was incorrect :/ Makes me wonder if maybe we should just use futhark after all...
Diffstat (limited to 'src/js')
-rw-r--r-- | src/js/javascript.nim | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/js/javascript.nim b/src/js/javascript.nim index 78999668..f402655c 100644 --- a/src/js/javascript.nim +++ b/src/js/javascript.nim @@ -1609,8 +1609,9 @@ fast array elements: {m.fast_array_elements} {m.fast_array_elements*sizeof(JSVal binary objects: {m.binary_object_count} {m.binary_object_size}""" proc eval*(ctx: JSContext, s: string, file: string, eval_flags: int): JSValue = - return JS_Eval(ctx, cstring(s), cint(s.len), cstring(file), cint(eval_flags)) + return JS_Eval(ctx, cstring(s), csize_t(s.len), cstring(file), + cint(eval_flags)) proc compileModule*(ctx: JSContext, s: string, file: cstring): JSValue = - return JS_Eval(ctx, cstring(s), cint(s.len), file, + return JS_Eval(ctx, cstring(s), csize_t(s.len), file, cint(JS_EVAL_TYPE_MODULE or JS_EVAL_FLAG_COMPILE_ONLY)) |