Skip to content

Commit

Permalink
Add allow(stable_features).
Browse files Browse the repository at this point in the history
Needed to pass deny-warnings on CI without breaking older nightlies.
  • Loading branch information
Dirbaio committed Oct 2, 2023
1 parent e632f16 commit 15b2f2f
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 3 deletions.
5 changes: 5 additions & 0 deletions embedded-hal-async/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
#![doc = include_str!("../README.md")]
#![warn(missing_docs)]
#![no_std]
// disable warning for already-stabilized features.
// Needed to pass CI, because we deny warnings.
// We don't immediately remove them to not immediately break older nightlies.
// When all features are stable, we'll remove them.
#![allow(stable_features)]
#![feature(async_fn_in_trait, impl_trait_projections)]

pub mod delay;
Expand Down
5 changes: 5 additions & 0 deletions embedded-hal-bus/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
#![warn(missing_docs)]
#![cfg_attr(not(feature = "std"), no_std)]
#![cfg_attr(docsrs, feature(doc_cfg))]
// disable warning for already-stabilized features.
// Needed to pass CI, because we deny warnings.
// We don't immediately remove them to not immediately break older nightlies.
// When all features are stable, we'll remove them.
#![cfg_attr(feature = "async", stable_features)]
#![cfg_attr(feature = "async", feature(async_fn_in_trait, impl_trait_projections))]

// needed to prevent defmt macros from breaking, since they emit code that does `defmt::blahblah`.
Expand Down
12 changes: 10 additions & 2 deletions embedded-io-adapters/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
#![cfg_attr(not(feature = "std"), no_std)]
#![cfg_attr(docsrs, feature(doc_cfg))]
#![warn(missing_docs)]
#![doc = include_str!("../README.md")]
// disable warning for already-stabilized features.
// Needed to pass CI, because we deny warnings.
// We don't immediately remove them to not immediately break older nightlies.
// When all features are stable, we'll remove them.
#![cfg_attr(
any(feature = "tokio-1", feature = "futures-03"),
allow(stable_features)
)]
#![cfg_attr(
any(feature = "tokio-1", feature = "futures-03"),
feature(async_fn_in_trait, impl_trait_projections)
)]
#![warn(missing_docs)]
#![doc = include_str!("../README.md")]

#[cfg(feature = "std")]
#[cfg_attr(docsrs, doc(cfg(feature = "std")))]
Expand Down
7 changes: 6 additions & 1 deletion embedded-io-async/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
#![feature(async_fn_in_trait, impl_trait_projections)]
#![cfg_attr(not(feature = "std"), no_std)]
#![cfg_attr(docsrs, feature(doc_cfg))]
#![warn(missing_docs)]
#![doc = include_str!("../README.md")]
// disable warning for already-stabilized features.
// Needed to pass CI, because we deny warnings.
// We don't immediately remove them to not immediately break older nightlies.
// When all features are stable, we'll remove them.
#![allow(stable_features)]
#![feature(async_fn_in_trait, impl_trait_projections)]

#[cfg(feature = "alloc")]
extern crate alloc;
Expand Down

0 comments on commit 15b2f2f

Please sign in to comment.