diff --git a/core/src/lib.rs b/core/src/lib.rs index bbe42adc26a..6f35a0d72e4 100644 --- a/core/src/lib.rs +++ b/core/src/lib.rs @@ -29,7 +29,7 @@ //! - The [`UpgradeInfo`], [`InboundUpgrade`] and [`OutboundUpgrade`] traits define how to upgrade //! each individual substream to use a protocol. See the `upgrade` module. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod proto { #![allow(unreachable_pub)] diff --git a/identity/src/lib.rs b/identity/src/lib.rs index 4f4313e8f17..b24c6cbf2ec 100644 --- a/identity/src/lib.rs +++ b/identity/src/lib.rs @@ -33,7 +33,7 @@ //! (e.g. [ed25519 binary format](https://datatracker.ietf.org/doc/html/rfc8032#section-5.1.5)). //! All key types have functions to enable conversion to/from their binary representations. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] #![allow(unreachable_pub)] #[cfg(any( feature = "ecdsa", diff --git a/libp2p/src/lib.rs b/libp2p/src/lib.rs index 42461f8ef8e..da8449716de 100644 --- a/libp2p/src/lib.rs +++ b/libp2p/src/lib.rs @@ -30,7 +30,7 @@ #![doc(html_logo_url = "https://libp2p.io/img/logo_small.png")] #![doc(html_favicon_url = "https://libp2p.io/img/favicon.png")] -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] pub use bytes; pub use futures; diff --git a/misc/metrics/src/lib.rs b/misc/metrics/src/lib.rs index 1fd79e7846f..e53991b65e6 100644 --- a/misc/metrics/src/lib.rs +++ b/misc/metrics/src/lib.rs @@ -25,7 +25,7 @@ //! //! See `examples` directory for more. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod bandwidth; #[cfg(feature = "dcutr")] diff --git a/misc/multistream-select/src/lib.rs b/misc/multistream-select/src/lib.rs index 725c3a0e2ba..53a97d99b0d 100644 --- a/misc/multistream-select/src/lib.rs +++ b/misc/multistream-select/src/lib.rs @@ -88,7 +88,7 @@ //! }); //! ``` -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod dialer_select; mod length_delimited; diff --git a/misc/quick-protobuf-codec/src/lib.rs b/misc/quick-protobuf-codec/src/lib.rs index cd090546bbc..4e9aa22e5df 100644 --- a/misc/quick-protobuf-codec/src/lib.rs +++ b/misc/quick-protobuf-codec/src/lib.rs @@ -1,4 +1,4 @@ -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{io, marker::PhantomData}; diff --git a/misc/quickcheck-ext/src/lib.rs b/misc/quickcheck-ext/src/lib.rs index 9c2deec8743..c7140cbd2fd 100644 --- a/misc/quickcheck-ext/src/lib.rs +++ b/misc/quickcheck-ext/src/lib.rs @@ -1,4 +1,4 @@ -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use core::ops::Range; diff --git a/misc/rw-stream-sink/src/lib.rs b/misc/rw-stream-sink/src/lib.rs index 28b5d9e659c..e1626942780 100644 --- a/misc/rw-stream-sink/src/lib.rs +++ b/misc/rw-stream-sink/src/lib.rs @@ -25,7 +25,7 @@ //! Each call to [`AsyncWrite::poll_write`] will send one packet to the sink. //! Calls to [`AsyncRead::poll_read`] will read from the stream's incoming packets. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{ io::{self, Read}, diff --git a/muxers/mplex/src/lib.rs b/muxers/mplex/src/lib.rs index 5b2e59a5904..5c298c685d8 100644 --- a/muxers/mplex/src/lib.rs +++ b/muxers/mplex/src/lib.rs @@ -20,7 +20,7 @@ //! Implementation of the Stream Multiplexer [Mplex](https://github.com/libp2p/specs/blob/master/mplex/README.md) protocol. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod codec; mod config; diff --git a/muxers/yamux/src/lib.rs b/muxers/yamux/src/lib.rs index 148f326e85b..1aa34ec49dc 100644 --- a/muxers/yamux/src/lib.rs +++ b/muxers/yamux/src/lib.rs @@ -20,7 +20,7 @@ //! Implementation of the [Yamux](https://github.com/hashicorp/yamux/blob/master/spec.md) multiplexing protocol for libp2p. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{ collections::VecDeque, diff --git a/protocols/autonat/src/lib.rs b/protocols/autonat/src/lib.rs index e49eaadcb83..36d2af7fcee 100644 --- a/protocols/autonat/src/lib.rs +++ b/protocols/autonat/src/lib.rs @@ -1,4 +1,4 @@ -#![cfg_attr(docsrs, feature(doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] #[cfg(feature = "v1")] pub mod v1; diff --git a/protocols/autonat/src/v1.rs b/protocols/autonat/src/v1.rs index 4de601c5df5..a7e931e8c87 100644 --- a/protocols/autonat/src/v1.rs +++ b/protocols/autonat/src/v1.rs @@ -24,7 +24,7 @@ //! This version of the protocol will eventually be deprecated in favor of [v2](crate::v2). //! We recommend using v2 for new projects. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] pub(crate) mod behaviour; pub(crate) mod protocol; diff --git a/protocols/dcutr/src/lib.rs b/protocols/dcutr/src/lib.rs index 7c5d28aba19..e7b8b0ce015 100644 --- a/protocols/dcutr/src/lib.rs +++ b/protocols/dcutr/src/lib.rs @@ -21,7 +21,7 @@ //! Implementation of the [libp2p Direct Connection Upgrade through Relay //! specification](https://github.com/libp2p/specs/blob/master/relay/DCUtR.md). -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod behaviour; mod handler; diff --git a/protocols/floodsub/src/lib.rs b/protocols/floodsub/src/lib.rs index ec4e2cf1b30..84308b43e55 100644 --- a/protocols/floodsub/src/lib.rs +++ b/protocols/floodsub/src/lib.rs @@ -20,7 +20,7 @@ //! Implementation of the [floodsub](https://github.com/libp2p/specs/blob/master/pubsub/README.md) protocol. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use libp2p_identity::PeerId; diff --git a/protocols/gossipsub/src/lib.rs b/protocols/gossipsub/src/lib.rs index f1d42d6cddb..ab5336e0366 100644 --- a/protocols/gossipsub/src/lib.rs +++ b/protocols/gossipsub/src/lib.rs @@ -92,7 +92,7 @@ //! //! For an example on how to use gossipsub, see the [chat-example](https://github.com/libp2p/rust-libp2p/tree/master/examples/chat). -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod backoff; mod behaviour; diff --git a/protocols/identify/src/lib.rs b/protocols/identify/src/lib.rs index 868ace87aeb..814f34e73ee 100644 --- a/protocols/identify/src/lib.rs +++ b/protocols/identify/src/lib.rs @@ -39,7 +39,7 @@ //! that negotiates and executes the protocol on every established connection, emitting //! [`Event`]s. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] pub use self::{ behaviour::{Behaviour, Config, Event}, diff --git a/protocols/kad/src/lib.rs b/protocols/kad/src/lib.rs index 5201832a2ba..7d0412bbf1d 100644 --- a/protocols/kad/src/lib.rs +++ b/protocols/kad/src/lib.rs @@ -33,7 +33,7 @@ //! existing nodes in the kademlia network cannot obtain the listen addresses //! of nodes querying them, and thus will not be able to add them to their routing table. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod addresses; mod behaviour; diff --git a/protocols/mdns/src/lib.rs b/protocols/mdns/src/lib.rs index 836a6b2426a..f17d0a5e25d 100644 --- a/protocols/mdns/src/lib.rs +++ b/protocols/mdns/src/lib.rs @@ -32,7 +32,7 @@ //! which implements the `NetworkBehaviour` trait. This struct will automatically discover other //! libp2p nodes on the local network. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{ net::{Ipv4Addr, Ipv6Addr}, diff --git a/protocols/perf/src/lib.rs b/protocols/perf/src/lib.rs index 191374cf9b8..f2f6894cf92 100644 --- a/protocols/perf/src/lib.rs +++ b/protocols/perf/src/lib.rs @@ -22,7 +22,7 @@ //! //! Do not use in untrusted environments. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::fmt::Display; diff --git a/protocols/ping/src/lib.rs b/protocols/ping/src/lib.rs index d48bcbc98ab..6a6a4b777b1 100644 --- a/protocols/ping/src/lib.rs +++ b/protocols/ping/src/lib.rs @@ -49,7 +49,7 @@ //! [`Swarm`]: libp2p_swarm::Swarm //! [`Transport`]: libp2p_core::Transport -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod handler; mod protocol; diff --git a/protocols/relay/src/lib.rs b/protocols/relay/src/lib.rs index 515fb40ef4b..94e88658891 100644 --- a/protocols/relay/src/lib.rs +++ b/protocols/relay/src/lib.rs @@ -21,7 +21,7 @@ //! Implementation of libp2p [circuit relay](https://github.com/libp2p/specs/blob/master/relay/README.md) protocol. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod behaviour; mod copy_future; diff --git a/protocols/rendezvous/src/lib.rs b/protocols/rendezvous/src/lib.rs index 221178728af..9a51af25651 100644 --- a/protocols/rendezvous/src/lib.rs +++ b/protocols/rendezvous/src/lib.rs @@ -20,7 +20,7 @@ //! Implementation of the [Rendezvous](https://github.com/libp2p/specs/blob/master/rendezvous/README.md) protocol. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use libp2p_swarm::StreamProtocol; diff --git a/protocols/request-response/src/lib.rs b/protocols/request-response/src/lib.rs index 1ac781b5744..5f5fab61ad7 100644 --- a/protocols/request-response/src/lib.rs +++ b/protocols/request-response/src/lib.rs @@ -64,7 +64,7 @@ //! advertised during inbound respectively outbound protocol negotiation //! on the substreams. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] #[cfg(feature = "cbor")] pub mod cbor; diff --git a/protocols/upnp/src/behaviour.rs b/protocols/upnp/src/behaviour.rs index 157cd01e06c..11eb393873b 100644 --- a/protocols/upnp/src/behaviour.rs +++ b/protocols/upnp/src/behaviour.rs @@ -18,7 +18,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{ borrow::Borrow, diff --git a/protocols/upnp/src/lib.rs b/protocols/upnp/src/lib.rs index d7a746f78df..07be68b25c9 100644 --- a/protocols/upnp/src/lib.rs +++ b/protocols/upnp/src/lib.rs @@ -25,7 +25,7 @@ //! This struct will automatically try to map the ports externally to internal //! addresses on the gateway. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] #[cfg(feature = "tokio")] mod behaviour; diff --git a/swarm-derive/src/lib.rs b/swarm-derive/src/lib.rs index 871f0b5815e..073a65d026e 100644 --- a/swarm-derive/src/lib.rs +++ b/swarm-derive/src/lib.rs @@ -19,7 +19,7 @@ // DEALINGS IN THE SOFTWARE. #![recursion_limit = "256"] -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod syn_ext; diff --git a/swarm/src/lib.rs b/swarm/src/lib.rs index d0ae6118190..6063cf06ef8 100644 --- a/swarm/src/lib.rs +++ b/swarm/src/lib.rs @@ -51,7 +51,7 @@ //! remote should behave: how to handle incoming substreams, which protocols //! are supported, when to open a new outbound substream, etc. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod connection; mod executor; diff --git a/transports/dns/src/lib.rs b/transports/dns/src/lib.rs index c2e330e329e..cfe9f39223e 100644 --- a/transports/dns/src/lib.rs +++ b/transports/dns/src/lib.rs @@ -53,7 +53,7 @@ //! //! [trust-dns-resolver]: https://docs.rs/trust-dns-resolver/latest/trust_dns_resolver/#dns-over-tls-and-dns-over-https -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] #[cfg(feature = "tokio")] pub mod tokio { diff --git a/transports/noise/src/lib.rs b/transports/noise/src/lib.rs index e05556744fe..9c77128b1e6 100644 --- a/transports/noise/src/lib.rs +++ b/transports/noise/src/lib.rs @@ -55,7 +55,7 @@ //! //! [noise]: http://noiseprotocol.org/ -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod io; mod protocol; diff --git a/transports/plaintext/src/lib.rs b/transports/plaintext/src/lib.rs index f841a859a62..fb7443eb8e9 100644 --- a/transports/plaintext/src/lib.rs +++ b/transports/plaintext/src/lib.rs @@ -20,7 +20,7 @@ //! Implementation of the [plaintext](https://github.com/libp2p/specs/blob/master/plaintext/README.md) protocol. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{ io, iter, diff --git a/transports/pnet/src/lib.rs b/transports/pnet/src/lib.rs index b27f9777c47..17f2f1966b3 100644 --- a/transports/pnet/src/lib.rs +++ b/transports/pnet/src/lib.rs @@ -23,7 +23,7 @@ //! Libp2p nodes configured with a pre-shared key can only communicate with other nodes with //! the same key. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod crypt_writer; use std::{ diff --git a/transports/quic/src/lib.rs b/transports/quic/src/lib.rs index a3346eaa4a7..d8f19500dba 100644 --- a/transports/quic/src/lib.rs +++ b/transports/quic/src/lib.rs @@ -58,7 +58,7 @@ //! QUIC connections do not need to be upgraded. You will get a compile-time error if you try. //! Instead, you must pass all needed configuration into the constructor. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod config; mod connection; diff --git a/transports/tcp/src/lib.rs b/transports/tcp/src/lib.rs index f91eee63085..f3489d8d8d4 100644 --- a/transports/tcp/src/lib.rs +++ b/transports/tcp/src/lib.rs @@ -26,7 +26,7 @@ //! which implement the [`libp2p_core::Transport`] trait for use as a //! transport with `libp2p-core` or `libp2p-swarm`. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] mod provider; diff --git a/transports/tls/src/lib.rs b/transports/tls/src/lib.rs index 57d7d69d4bd..43268d0af8c 100644 --- a/transports/tls/src/lib.rs +++ b/transports/tls/src/lib.rs @@ -23,7 +23,7 @@ //! //! See . -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] pub mod certificate; mod upgrade; diff --git a/transports/uds/src/lib.rs b/transports/uds/src/lib.rs index 082bc831bc9..8bcfd1da411 100644 --- a/transports/uds/src/lib.rs +++ b/transports/uds/src/lib.rs @@ -32,7 +32,7 @@ //! documentation of `core` and of libp2p in general to learn how to use the `Transport` trait. #![cfg(all(unix, not(target_os = "emscripten"), feature = "tokio"))] -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] use std::{ collections::VecDeque, diff --git a/transports/webrtc/src/lib.rs b/transports/webrtc/src/lib.rs index 99f0c7da658..d83f4bb2d27 100644 --- a/transports/webrtc/src/lib.rs +++ b/transports/webrtc/src/lib.rs @@ -79,7 +79,7 @@ //! is to make the hash a part of the remote's multiaddr. On the server side, we turn //! certificate verification off. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] #[cfg(feature = "tokio")] pub mod tokio; diff --git a/transports/websocket/src/lib.rs b/transports/websocket/src/lib.rs index 71339488525..0c5997584bc 100644 --- a/transports/websocket/src/lib.rs +++ b/transports/websocket/src/lib.rs @@ -20,7 +20,7 @@ //! Implementation of the libp2p `Transport` trait for Websockets. -#![cfg_attr(docsrs, feature(doc_cfg, doc_auto_cfg))] +#![cfg_attr(docsrs, feature(doc_cfg))] pub mod error; pub mod framed;