Make use of feature(doc_cfg) conditional on docsrs consistently

`feature(doc_cfg)` is turned on conditionally if `docsrs` is true in
most of the source code, but in some cases this isn't the case. This
change makes that consistent everywhere, fixing the doc build on stable
Rust.

Fixes #506.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1381>
This commit is contained in:
Martin Robinson 2024-02-01 16:21:46 +01:00 committed by GStreamer Marge Bot
parent fde0c061c2
commit 230c906626
3 changed files with 3 additions and 3 deletions

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))] #![cfg_attr(docsrs, feature(doc_cfg))]
#![allow(clippy::missing_safety_doc)] #![allow(clippy::missing_safety_doc)]
pub use ffi; pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))] #![cfg_attr(docsrs, feature(doc_cfg))]
#![allow(clippy::missing_safety_doc)] #![allow(clippy::missing_safety_doc)]
pub use ffi; pub use ffi;

View file

@ -6,7 +6,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#![cfg_attr(all(not(doctest), doc), feature(doc_cfg))] #![cfg_attr(docsrs, feature(doc_cfg))]
#![allow(clippy::missing_safety_doc)] #![allow(clippy::missing_safety_doc)]
pub use ffi; pub use ffi;