diff --git a/mavlink-core/src/lib.rs b/mavlink-core/src/lib.rs index 0d3273c62b..2ef674b104 100644 --- a/mavlink-core/src/lib.rs +++ b/mavlink-core/src/lib.rs @@ -19,7 +19,7 @@ //! feature without also using the `uavionix` and `icarous` features. //! #![cfg_attr(not(feature = "std"), no_std)] -#![cfg_attr(any(docsrs, doc), feature(doc_auto_cfg))] +#![cfg_attr(all(any(docsrs, doc), not(doctest)), feature(doc_auto_cfg))] #![deny(clippy::all)] #![warn(clippy::use_self)] diff --git a/mavlink/src/lib.rs b/mavlink/src/lib.rs index 71790d96d9..bfdcbeafb2 100644 --- a/mavlink/src/lib.rs +++ b/mavlink/src/lib.rs @@ -1,5 +1,5 @@ #![cfg_attr(not(feature = "std"), no_std)] -#![cfg_attr(any(docsrs, doc), feature(doc_auto_cfg))] +#![cfg_attr(all(any(docsrs, doc), not(doctest)), feature(doc_auto_cfg))] // include generate definitions include!(concat!(env!("OUT_DIR"), "/mod.rs"));