diff --git a/src/double_priority_queue/mod.rs b/src/double_priority_queue/mod.rs index 0e139fb..c9ff33d 100644 --- a/src/double_priority_queue/mod.rs +++ b/src/double_priority_queue/mod.rs @@ -999,7 +999,7 @@ fn better_to_rebuild(len1: usize, len2: usize) -> bool { } #[cfg(feature = "serde")] -#![cfg_attr(docsrs, doc(cfg(feature = "serde")))] +#[cfg_attr(docsrs, doc(cfg(feature = "serde")))] mod serde { use std::cmp::{Eq, Ord}; use std::hash::{BuildHasher, Hash}; diff --git a/src/lib.rs b/src/lib.rs index 401cfff..6b2af2f 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -87,6 +87,7 @@ //! ``` #![cfg_attr(not(feature = "std"), no_std)] +#![cfg_attr(docsrs, feature(doc_cfg))] #[cfg(not(feature = "std"))] extern crate alloc; diff --git a/src/priority_queue/mod.rs b/src/priority_queue/mod.rs index fc2f2ae..99bdef2 100644 --- a/src/priority_queue/mod.rs +++ b/src/priority_queue/mod.rs @@ -791,7 +791,7 @@ fn better_to_rebuild(len1: usize, len2: usize) -> bool { } #[cfg(feature = "serde")] -#![cfg_attr(docsrs, doc(cfg(feature = "serde")))] +#[cfg_attr(docsrs, doc(cfg(feature = "serde")))] mod serde { use std::cmp::{Eq, Ord}; use std::hash::{BuildHasher, Hash};