Skip to main content

JS_NewBigInt128

Function JS_NewBigInt128 

Source
#[unsafe(no_mangle)]
pub unsafe extern "C" fn JS_NewBigInt128( ctx: *mut JsContext, low: u64, high: u64, ) -> JsValue
Expand description

JS_NewBigInt128: a BigInt from a 128-bit two’s-complement pair.

Built the way the reference builds it: the low and high halves are combined into limbs, then the sign is applied. low is unsigned in the header, so a negative value arrives as a high half whose top bit is set.

§Safety

ctx must be a live context.