Struct v8::BigInt [−][src]
#[repr(C)]pub struct BigInt(_);
Expand description
A JavaScript BigInt value (https://tc39.github.io/proposal-bigint)
Implementations
pub fn new_from_words<'s>(
scope: &mut HandleScope<'s>,
sign_bit: bool,
words: &[u64]
) -> Option<Local<'s, BigInt>>
pub fn new_from_words<'s>(
scope: &mut HandleScope<'s>,
sign_bit: bool,
words: &[u64]
) -> Option<Local<'s, BigInt>>
Creates a new BigInt object using a specified sign bit and a specified list of digits/words. The resulting number is calculated as:
(-1)^sign_bit * (words[0] * (2^64)^0 + words[1] * (2^64)^1 + …)
Returns the value of this BigInt as an unsigned 64-bit integer, and a
bool
indicating whether the return value was truncated was truncated or
wrapped around. In particular, it will be false
if this BigInt is
negative.
Returns the value of this BigInt as a signed 64-bit integer, and a bool
indicating whether this BigInt was truncated or not.
Returns the number of 64-bit words needed to store the result of
to_words_array
.