diff --git a/Cargo.toml b/Cargo.toml index 5a46b51..1cee089 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,6 +23,19 @@ default-members = [ "ste", ] +[workspace.package] +version = "0.2.0-alpha.4" +authors = ["John-John Tedro "] +# Generic associated types were stabilized in 1.65. +rust-version = "1.65" +edition = "2021" +documentation = "https://docs.rs/audio" +homepage = "https://github.com/udoprog/audio" +repository = "https://github.com/udoprog/audio" +license = "MIT/Apache-2.0" +keywords = ["audio", "buffer", "dsp"] +categories = ["multimedia::audio"] + [patch.'https://github.com/udoprog/audio'] audio = { path = "audio" } audio-core = { path = "audio-core" } diff --git a/audio-core/Cargo.toml b/audio-core/Cargo.toml index 9a76e1c..8e4c1ad 100644 --- a/audio-core/Cargo.toml +++ b/audio-core/Cargo.toml @@ -1,20 +1,20 @@ [package] name = "audio-core" -version = "0.2.0-alpha.4" -authors = ["John-John Tedro "] -edition = "2018" description = "The core audio traits" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true [features] default = ["std"] std = [] [dev-dependencies] -audio = { version = "0.2.0-alpha.4", path = "../audio" } +audio = { path = "../audio" } diff --git a/audio-device-alsa-sys/Cargo.toml b/audio-device-alsa-sys/Cargo.toml index ed4fc2e..a5584a1 100644 --- a/audio-device-alsa-sys/Cargo.toml +++ b/audio-device-alsa-sys/Cargo.toml @@ -1,16 +1,16 @@ [package] name = "audio-device-alsa-sys" -version = "0.1.0-alpha.1" -authors = ["John-John Tedro "] -edition = "2018" description = "audio-device system bindings for ALSA" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true [dependencies] libc = "0.2.125" diff --git a/audio-device-pipewire-sys/Cargo.toml b/audio-device-pipewire-sys/Cargo.toml index b7cb1a5..b022550 100644 --- a/audio-device-pipewire-sys/Cargo.toml +++ b/audio-device-pipewire-sys/Cargo.toml @@ -1,16 +1,16 @@ [package] name = "audio-device-pipewire-sys" -version = "0.1.0-alpha.1" -authors = ["John-John Tedro "] -edition = "2018" description = "audio-device system bindings for PipeWire" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true [dependencies] libc = "0.2.125" diff --git a/audio-device-pulse-sys/Cargo.toml b/audio-device-pulse-sys/Cargo.toml index bd5a7b6..7ee97c2 100644 --- a/audio-device-pulse-sys/Cargo.toml +++ b/audio-device-pulse-sys/Cargo.toml @@ -1,16 +1,16 @@ [package] name = "audio-device-pulse-sys" -version = "0.1.0-alpha.1" -authors = ["John-John Tedro "] -edition = "2018" description = "audio-device system bindings for PulseAudio" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true [dependencies] libc = "0.2.125" diff --git a/audio-device/Cargo.toml b/audio-device/Cargo.toml index 213f0dc..efa2060 100644 --- a/audio-device/Cargo.toml +++ b/audio-device/Cargo.toml @@ -1,16 +1,16 @@ [package] name = "audio-device" -version = "0.1.0-alpha.6" -authors = ["John-John Tedro "] -edition = "2018" description = "A library for interacting with audio devices" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true autoexamples = false @@ -42,21 +42,21 @@ wasapi = [ [dependencies] tracing = "0.1.36" -audio-core = { version = "0.2.0-alpha.4", path = "../audio-core" } +audio-core = { path = "../audio-core" } thiserror = "1.0.31" rand = "0.8.5" -ste = { version = "0.1.0-alpha.9", path = "../ste" } +ste = { path = "../ste" } -pulse-sys = { package = "audio-device-pulse-sys", version = "0.1.0-alpha.1", path = "../audio-device-pulse-sys", optional = true } -pipewire-sys = { package = "audio-device-pipewire-sys", version = "0.1.0-alpha.1", path = "../audio-device-pipewire-sys", optional = true } +pulse-sys = { package = "audio-device-pulse-sys", path = "../audio-device-pulse-sys", optional = true } +pipewire-sys = { package = "audio-device-pipewire-sys", path = "../audio-device-pipewire-sys", optional = true } # unix -alsa-sys = { package = "audio-device-alsa-sys", version = "0.1.0-alpha.1", path = "../audio-device-alsa-sys", optional = true } +alsa-sys = { package = "audio-device-alsa-sys", path = "../audio-device-alsa-sys", optional = true } libc = { version = "0.2.125", optional = true } [dev-dependencies] -audio = { version = "0.2.0-alpha.4", path = "../audio" } -audio-generator = { version = "0.1.0-alpha.2", path = "../audio-generator" } +audio = { path = "../audio" } +audio-generator = { path = "../audio-generator" } anyhow = "1.0.57" tokio = { version = "1.18.1", features = ["full"] } tracing-subscriber = { version = "0.3.3", features = ["env-filter"] } diff --git a/audio-generator/Cargo.toml b/audio-generator/Cargo.toml index 1037be9..072aec1 100644 --- a/audio-generator/Cargo.toml +++ b/audio-generator/Cargo.toml @@ -1,16 +1,16 @@ [package] name = "audio-generator" -version = "0.1.0-alpha.2" -authors = ["John-John Tedro "] -edition = "2018" description = "Audio generator APIs" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true [dependencies] -audio-core = { version = "0.2.0-alpha.4", path = "../audio-core" } +audio-core = { path = "../audio-core" } diff --git a/audio/Cargo.toml b/audio/Cargo.toml index 09bc399..f56fe1b 100644 --- a/audio/Cargo.toml +++ b/audio/Cargo.toml @@ -1,23 +1,23 @@ [package] name = "audio" -version = "0.2.0-alpha.4" -authors = ["John-John Tedro "] -edition = "2018" description = "A crate for working with audio in Rust" -documentation = "https://docs.rs/audio" -readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" -keywords = ["audio", "buffer", "dsp"] -categories = ["multimedia::audio"] +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +documentation.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true +keywords.workspace = true +categories.workspace = true [features] default = ["std"] std = ["audio-core/std"] [dependencies] -audio-core = { version = "0.2.0-alpha.4", path = "../audio-core" } +audio-core = { path = "../audio-core" } [dev-dependencies] rand = "0.8.5" diff --git a/examples/Cargo.toml b/examples/Cargo.toml index 8083f3f..ce5a310 100644 --- a/examples/Cargo.toml +++ b/examples/Cargo.toml @@ -2,7 +2,7 @@ name = "examples" version = "0.0.0" authors = ["John-John Tedro "] -edition = "2018" +edition.workspace = true publish = false [dependencies] diff --git a/generate/Cargo.toml b/generate/Cargo.toml index 1a3af39..8323afd 100644 --- a/generate/Cargo.toml +++ b/generate/Cargo.toml @@ -2,7 +2,7 @@ name = "generate" version = "0.0.0" authors = ["John-John Tedro "] -edition = "2018" +edition.workspace = true publish = false [dependencies] diff --git a/ste/Cargo.toml b/ste/Cargo.toml index 6e014cf..ce4ec46 100644 --- a/ste/Cargo.toml +++ b/ste/Cargo.toml @@ -1,14 +1,15 @@ [package] name = "ste" -version = "0.1.0-alpha.11" -authors = ["John-John Tedro "] -edition = "2018" description = "A single-threaded executor with some tricks up its sleeve." documentation = "https://docs.rs/audio" readme = "README.md" -homepage = "https://github.com/udoprog/audio" -repository = "https://github.com/udoprog/audio" -license = "MIT/Apache-2.0" +version.workspace = true +authors.workspace = true +rust-version.workspace = true +edition.workspace = true +homepage.workspace = true +repository.workspace = true +license.workspace = true keywords = ["executor", "thread"] categories = ["concurrency"] diff --git a/ste/src/lib.rs b/ste/src/lib.rs index 8c3c34b..b402216 100644 --- a/ste/src/lib.rs +++ b/ste/src/lib.rs @@ -342,6 +342,7 @@ impl Thread { move |tag| { if let Some(task) = task.take() { let _ = panic::catch_unwind(panic::AssertUnwindSafe(|| { + let _ = &storage; let output = with_tag(tag, task); // Safety: we're the only one with access to this pointer, @@ -632,6 +633,7 @@ impl Builder { let handle = thread::Builder::new() .name(String::from("ste-thread")) .spawn(move || { + let _ = &shared2; let RawSend(shared) = shared2; #[cfg(feature = "tokio")] diff --git a/ste/src/wait_future.rs b/ste/src/wait_future.rs index 475b237..75e4251 100644 --- a/ste/src/wait_future.rs +++ b/ste/src/wait_future.rs @@ -72,6 +72,7 @@ where use std::panic; move |tag| { + let _ = (&waker, &future, &complete); unsafe { // Safety: At this point, we know the waker has been // replaced by the polling task and can safely deref it into @@ -82,6 +83,7 @@ where let future = Pin::new_unchecked(future.0.as_mut()); let result = panic::catch_unwind(panic::AssertUnwindSafe(|| { + let _ = &output; if let Poll::Ready(ready) = with_tag(tag, || future.poll(&mut cx)) { *output.0.as_mut() = Some(ready); }