summaryrefslogtreecommitdiff
path: root/quickjs.c
diff options
context:
space:
mode:
Diffstat (limited to 'quickjs.c')
-rw-r--r--quickjs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/quickjs.c b/quickjs.c
index c3db038..2c1ac6b 100644
--- a/quickjs.c
+++ b/quickjs.c
@@ -34907,7 +34907,7 @@ static int JS_WriteBigNum(BCWriterState *s, JSValueConst obj)
e = a->expn + 3;
else
e = a->expn;
- e = (e << 1) | a->sign;
+ e = (e * 2) | a->sign;
if (e < INT32_MIN || e > INT32_MAX) {
JS_ThrowInternalError(s->ctx, "bignum exponent is too large");
return -1;