Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makes slice argument of web_sys::AudioBuffer::copy_to_channel* non mutable (#2434) #2436

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions crates/web-sys/src/features/gen_AudioBuffer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ extern "C" {
#[doc = "*This API requires the following crate features to be activated: `AudioBuffer`*"]
pub fn copy_to_channel(
this: &AudioBuffer,
source: &mut [f32],
source: &[f32],
channel_number: i32,
) -> Result<(), JsValue>;
# [wasm_bindgen (catch , method , structural , js_class = "AudioBuffer" , js_name = copyToChannel)]
Expand All @@ -89,7 +89,7 @@ extern "C" {
#[doc = "*This API requires the following crate features to be activated: `AudioBuffer`*"]
pub fn copy_to_channel_with_start_in_channel(
this: &AudioBuffer,
source: &mut [f32],
source: &[f32],
channel_number: i32,
start_in_channel: u32,
) -> Result<(), JsValue>;
Expand Down
2 changes: 2 additions & 0 deletions crates/webidl/src/constants.rs
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,8 @@ lazy_static! {
"setBindGroup",
"writeBuffer",
"writeTexture",
// AudioBuffer
"copyToChannel"
// TODO: Add another type's functions here. Leave a comment header with the type name
]);
}