From 230c9066269b74a82cc8b2389d07984d78d97f71 Mon Sep 17 00:00:00 2001 From: Martin Robinson Date: Thu, 1 Feb 2024 16:21:46 +0100 Subject: [PATCH] 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: --- gstreamer-gl/egl/src/lib.rs | 2 +- gstreamer-gl/wayland/src/lib.rs | 2 +- gstreamer-gl/x11/src/lib.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/gstreamer-gl/egl/src/lib.rs b/gstreamer-gl/egl/src/lib.rs index 487f3a07f..b7d41b3f0 100644 --- a/gstreamer-gl/egl/src/lib.rs +++ b/gstreamer-gl/egl/src/lib.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // 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)] pub use ffi; diff --git a/gstreamer-gl/wayland/src/lib.rs b/gstreamer-gl/wayland/src/lib.rs index 8626d3d36..2319df34b 100644 --- a/gstreamer-gl/wayland/src/lib.rs +++ b/gstreamer-gl/wayland/src/lib.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // 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)] pub use ffi; diff --git a/gstreamer-gl/x11/src/lib.rs b/gstreamer-gl/x11/src/lib.rs index 7358eaa08..687dc9b4e 100644 --- a/gstreamer-gl/x11/src/lib.rs +++ b/gstreamer-gl/x11/src/lib.rs @@ -6,7 +6,7 @@ // option. This file may not be copied, modified, or distributed // 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)] pub use ffi;