diff options
author | Joel Galenson <jgalenson@google.com> | 2021-08-10 17:35:19 +0000 |
---|---|---|
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | 2021-08-10 17:35:19 +0000 |
commit | bae11a009eb634aacdb7cf547121f1d44b8b53be (patch) | |
tree | 7f245f0a8c582ff0442bc535ce222bc1b7566142 | |
parent | 335f1c1d4f15565a20609fe05d7383560e81f003 (diff) | |
parent | f50c78e7b1eedd0221b3b0952958147dc59661f1 (diff) | |
download | futures-channel-bae11a009eb634aacdb7cf547121f1d44b8b53be.tar.gz |
Upgrade rust/crates/futures-channel to 0.3.16 am: e8695389e1 am: 67b97058ad am: 77e4c2ab1c am: f50c78e7b1
Original change: https://android-review.googlesource.com/c/platform/external/rust/crates/futures-channel/+/1791030
Change-Id: Ib0ba3d8049e012dbfa5bbb4bece3583600cde72a
-rw-r--r-- | .cargo_vcs_info.json | 2 | ||||
-rw-r--r-- | Android.bp | 2 | ||||
-rw-r--r-- | Cargo.toml | 15 | ||||
-rw-r--r-- | Cargo.toml.orig | 6 | ||||
-rw-r--r-- | METADATA | 8 | ||||
-rw-r--r-- | build.rs | 2 | ||||
-rw-r--r-- | no_atomic_cas.rs | 2 | ||||
-rw-r--r-- | src/lib.rs | 48 | ||||
-rw-r--r-- | src/mpsc/mod.rs | 3 |
9 files changed, 46 insertions, 42 deletions
diff --git a/.cargo_vcs_info.json b/.cargo_vcs_info.json index ec6442e..99dc8b0 100644 --- a/.cargo_vcs_info.json +++ b/.cargo_vcs_info.json @@ -1,5 +1,5 @@ { "git": { - "sha1": "fc080d153bc7bf00429ec5e2b91e2f21f2243846" + "sha1": "ab38fd29d3f84f8fc028fa7883e53dba423da0ee" } } @@ -64,4 +64,4 @@ rust_library { } // dependent_library ["feature_list"] -// futures-core-0.3.15 "alloc,std" +// futures-core-0.3.16 "alloc,std" @@ -3,17 +3,16 @@ # When uploading crates to the registry Cargo will automatically # "normalize" Cargo.toml files for maximal compatibility # with all versions of Cargo and also rewrite `path` dependencies -# to registry (e.g., crates.io) dependencies +# to registry (e.g., crates.io) dependencies. # -# If you believe there's an error in this file please file an -# issue against the rust-lang/cargo repository. If you're -# editing this file be aware that the upstream Cargo.toml -# will likely look very different (and much more reasonable) +# If you are reading this file be aware that the original Cargo.toml +# will likely look very different (and much more reasonable). +# See Cargo.toml.orig for the original contents. [package] edition = "2018" name = "futures-channel" -version = "0.3.15" +version = "0.3.16" authors = ["Alex Crichton <alex@alexcrichton.com>"] description = "Channels for asynchronous communication using futures-rs.\n" homepage = "https://rust-lang.github.io/futures-rs" @@ -24,11 +23,11 @@ repository = "https://github.com/rust-lang/futures-rs" all-features = true rustdoc-args = ["--cfg", "docsrs"] [dependencies.futures-core] -version = "0.3.15" +version = "0.3.16" default-features = false [dependencies.futures-sink] -version = "0.3.15" +version = "0.3.16" optional = true default-features = false diff --git a/Cargo.toml.orig b/Cargo.toml.orig index fae78a0..1d3cb74 100644 --- a/Cargo.toml.orig +++ b/Cargo.toml.orig @@ -1,7 +1,7 @@ [package] name = "futures-channel" edition = "2018" -version = "0.3.15" +version = "0.3.16" authors = ["Alex Crichton <alex@alexcrichton.com>"] license = "MIT OR Apache-2.0" repository = "https://github.com/rust-lang/futures-rs" @@ -23,8 +23,8 @@ unstable = [] cfg-target-has-atomic = [] [dependencies] -futures-core = { path = "../futures-core", version = "0.3.15", default-features = false } -futures-sink = { path = "../futures-sink", version = "0.3.15", default-features = false, optional = true } +futures-core = { path = "../futures-core", version = "0.3.16", default-features = false } +futures-sink = { path = "../futures-sink", version = "0.3.16", default-features = false, optional = true } [dev-dependencies] futures = { path = "../futures", default-features = true } @@ -7,13 +7,13 @@ third_party { } url { type: ARCHIVE - value: "https://static.crates.io/crates/futures-channel/futures-channel-0.3.15.crate" + value: "https://static.crates.io/crates/futures-channel/futures-channel-0.3.16.crate" } - version: "0.3.15" + version: "0.3.16" license_type: NOTICE last_upgrade_date { year: 2021 - month: 5 - day: 19 + month: 8 + day: 9 } } @@ -8,7 +8,7 @@ include!("no_atomic_cas.rs"); // and outside of the normal semver guarantees: // // - `futures_no_atomic_cas` -// Assume the target does not have atomic CAS (compare-and-swap). +// Assume the target does *not* support atomic CAS operations. // This is usually detected automatically by the build script, but you may // need to enable it manually when building for custom targets or using // non-cargo build systems that don't run the build script. diff --git a/no_atomic_cas.rs b/no_atomic_cas.rs index 0819af1..4708bf8 100644 --- a/no_atomic_cas.rs +++ b/no_atomic_cas.rs @@ -3,6 +3,8 @@ const NO_ATOMIC_CAS_TARGETS: &[&str] = &[ "avr-unknown-gnu-atmega328", + "bpfeb-unknown-none", + "bpfel-unknown-none", "msp430-none-elf", "riscv32i-unknown-none-elf", "riscv32imc-unknown-none-elf", @@ -12,27 +12,31 @@ //! library is activated, and it is activated by default. #![cfg_attr(not(feature = "std"), no_std)] -#![warn(missing_docs, missing_debug_implementations, rust_2018_idioms, unreachable_pub)] -// It cannot be included in the published code because this lints have false positives in the minimum required version. -#![cfg_attr(test, warn(single_use_lifetimes))] -#![warn(clippy::all)] -#![doc(test(attr(deny(warnings), allow(dead_code, unused_assignments, unused_variables))))] +#![warn( + missing_debug_implementations, + missing_docs, + rust_2018_idioms, + single_use_lifetimes, + unreachable_pub +)] +#![doc(test( + no_crate_inject, + attr( + deny(warnings, rust_2018_idioms, single_use_lifetimes), + allow(dead_code, unused_assignments, unused_variables) + ) +))] -macro_rules! cfg_target_has_atomic { - ($($item:item)*) => {$( - #[cfg(not(futures_no_atomic_cas))] - $item - )*}; -} +#[cfg(not(futures_no_atomic_cas))] +#[cfg(feature = "alloc")] +extern crate alloc; -cfg_target_has_atomic! { - #[cfg(feature = "alloc")] - extern crate alloc; - - #[cfg(feature = "alloc")] - mod lock; - #[cfg(feature = "std")] - pub mod mpsc; - #[cfg(feature = "alloc")] - pub mod oneshot; -} +#[cfg(not(futures_no_atomic_cas))] +#[cfg(feature = "alloc")] +mod lock; +#[cfg(not(futures_no_atomic_cas))] +#[cfg(feature = "std")] +pub mod mpsc; +#[cfg(not(futures_no_atomic_cas))] +#[cfg(feature = "alloc")] +pub mod oneshot; diff --git a/src/mpsc/mod.rs b/src/mpsc/mod.rs index 28612da..44834b7 100644 --- a/src/mpsc/mod.rs +++ b/src/mpsc/mod.rs @@ -510,9 +510,8 @@ impl<T> BoundedSenderInner<T> { // Do the send without failing. // Can be called only by bounded sender. - #[allow(clippy::debug_assert_with_mut_call)] fn do_send_b(&mut self, msg: T) -> Result<(), TrySendError<T>> { - // Anyone callig do_send *should* make sure there is room first, + // Anyone calling do_send *should* make sure there is room first, // but assert here for tests as a sanity check. debug_assert!(self.poll_unparked(None).is_ready()); |