devela::_dep::web_sys::js_sys::Atomics

Function xor

Source
pub fn xor(
    typed_array: &JsValue,
    index: u32,
    value: i32,
) -> Result<i32, JsValue> 
Available on crate feature dep_web_sys only.
Expand description

The static Atomics.xor() method computes a bitwise XOR with a given value at a given position in the array, and returns the old value at that position. This atomic operation guarantees that no other write happens until the modified value is written back.

You should use xor_bigint to operate on a BigInt64Array or a BigUint64Array.

MDN documentation