about summary refs log tree commit diff stats
path: root/lib/quickjs
diff options
context:
space:
mode:
Diffstat (limited to 'lib/quickjs')
-rw-r--r--lib/quickjs/libbf.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/lib/quickjs/libbf.c b/lib/quickjs/libbf.c
index 63e7daeb..fe1628e7 100644
--- a/lib/quickjs/libbf.c
+++ b/lib/quickjs/libbf.c
@@ -235,13 +235,8 @@ int bf_set_ui(bf_t *r, uint64_t a)
         a0 = a;
         a1 = a >> 32;
         shift = clz(a1);
-        // shift < 32 because a > 0xffffffff
         r->tab[0] = a0 << shift;
-        if (shift == 0) {
-            r->tab[1] = a1;
-        } else {
-            r->tab[1] = (a1 << shift) | (a0 >> (LIMB_BITS - shift));
-        }
+        r->tab[1] = (a1 << shift) | (a0 >> (LIMB_BITS - shift));
         r->expn = 2 * LIMB_BITS - shift;
     }
 #endif