Skip to content

Commit 0759bfa

Browse files
author
ibaryshnikov
committed
f32 changed to f64 in Atomics
1 parent f1eaefd commit 0759bfa

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

crates/js-sys/src/lib.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,7 @@ pub mod Atomics {
529529
///
530530
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/add)
531531
#[wasm_bindgen(static_method_of = Atomics, catch)]
532-
pub fn add(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
532+
pub fn add(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
533533

534534
/// The static `Atomics.and()` method computes a bitwise AND with a given
535535
/// value at a given position in the array, and returns the old value
@@ -539,7 +539,7 @@ pub mod Atomics {
539539
///
540540
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/and)
541541
#[wasm_bindgen(static_method_of = Atomics, catch)]
542-
pub fn and(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
542+
pub fn and(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
543543

544544
/// The static `Atomics.compareExchange()` method exchanges a given
545545
/// replacement value at a given position in the array, if a given expected
@@ -553,9 +553,9 @@ pub mod Atomics {
553553
pub fn compare_exchange(
554554
typed_array: &JsValue,
555555
index: u32,
556-
expected_value: f32,
557-
replacement_value: f32,
558-
) -> Result<f32, JsValue>;
556+
expected_value: f64,
557+
replacement_value: f64,
558+
) -> Result<f64, JsValue>;
559559

560560
/// The static `Atomics.exchange()` method stores a given value at a given
561561
/// position in the array and returns the old value at that position.
@@ -564,7 +564,7 @@ pub mod Atomics {
564564
///
565565
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/exchange)
566566
#[wasm_bindgen(static_method_of = Atomics, catch)]
567-
pub fn exchange(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
567+
pub fn exchange(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
568568

569569
/// The static `Atomics.isLockFree()` method is used to determine
570570
/// whether to use locks or atomic operations. It returns true,
@@ -580,7 +580,7 @@ pub mod Atomics {
580580
///
581581
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/load)
582582
#[wasm_bindgen(static_method_of = Atomics, catch)]
583-
pub fn load(typed_array: &JsValue, index: u32) -> Result<f32, JsValue>;
583+
pub fn load(typed_array: &JsValue, index: u32) -> Result<f64, JsValue>;
584584

585585
/// The static `Atomics.notify()` method notifies up some agents that
586586
/// are sleeping in the wait queue.
@@ -597,14 +597,14 @@ pub mod Atomics {
597597
///
598598
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/or)
599599
#[wasm_bindgen(static_method_of = Atomics, catch)]
600-
pub fn or(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
600+
pub fn or(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
601601

602602
/// The static `Atomics.store()` method stores a given value at the given
603603
/// position in the array and returns that value.
604604
///
605605
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/store)
606606
#[wasm_bindgen(static_method_of = Atomics, catch)]
607-
pub fn store(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
607+
pub fn store(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
608608

609609
/// The static `Atomics.sub()` method substracts a given value at a
610610
/// given position in the array and returns the old value at that position.
@@ -613,7 +613,7 @@ pub mod Atomics {
613613
///
614614
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/sub)
615615
#[wasm_bindgen(static_method_of = Atomics, catch)]
616-
pub fn sub(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
616+
pub fn sub(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
617617

618618
/// The static `Atomics.wait()` method verifies that a given
619619
/// position in an `Int32Array` still contains a given value
@@ -634,7 +634,7 @@ pub mod Atomics {
634634
typed_array: &JsValue,
635635
index: u32,
636636
value: i32,
637-
timeout: f32,
637+
timeout: f64,
638638
) -> Result<JsValue, JsValue>;
639639

640640
/// The static `Atomics.xor()` method computes a bitwise XOR
@@ -645,7 +645,7 @@ pub mod Atomics {
645645
///
646646
/// [MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Atomics/xor)
647647
#[wasm_bindgen(static_method_of = Atomics, catch)]
648-
pub fn xor(typed_array: &JsValue, index: u32, value: f32) -> Result<f32, JsValue>;
648+
pub fn xor(typed_array: &JsValue, index: u32, value: f64) -> Result<f64, JsValue>;
649649
}
650650
}
651651

0 commit comments

Comments
 (0)