Skip to content

Commit 0bcc193

Browse files
committed
Add the docsrs autocfg attr to all crates
This also adds it to generated crates, and adds an autofix+lint to manage these attributes.
1 parent bb2c129 commit 0bcc193

File tree

37 files changed

+194
-12
lines changed

37 files changed

+194
-12
lines changed

CHANGELOG.next.toml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,3 +79,15 @@ message = "Expose local socket address from ConnectionMetadata."
7979
references = ["aws-sdk-rust#990"]
8080
meta = { "breaking" = false, "tada" = false, "bug" = false, "target" = "client" }
8181
author = "declanvk"
82+
83+
[[smithy-rs]]
84+
message = "All generated docs now include docsrs labels when features are required"
85+
references = ["smithy-rs#3121", "smithy-rs#3295"]
86+
meta = { "breaking" = false, "tada" = true, "bug" = false, "target" = "all" }
87+
author = "rcoh"
88+
89+
[[aws-sdk-rust]]
90+
message = "All generated docs now include docsrs labels when features are required"
91+
references = ["smithy-rs#3121", "smithy-rs#3295"]
92+
meta = { "breaking" = false, "tada" = true, "bug" = false }
93+
author = "rcoh"

aws/rust-runtime/aws-config/src/lib.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
#![allow(clippy::derive_partial_eq_without_eq)]
710
#![warn(
811
missing_debug_implementations,
@@ -11,7 +14,6 @@
1114
rustdoc::missing_crate_level_docs,
1215
unreachable_pub
1316
)]
14-
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
1517

1618
//! `aws-config` provides implementations of region and credential resolution.
1719
//!

aws/rust-runtime/aws-credential-types/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! `aws-credential-types` provides types concerned with AWS SDK credentials including:
710
//! * Traits for credentials providers and for credentials caching
811
//! * An opaque struct representing credentials

aws/rust-runtime/aws-endpoint/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,7 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! This crate is no longer used by the AWS SDK and is deprecated.

aws/rust-runtime/aws-http/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! AWS-specific middleware implementations and HTTP-related features.
710
811
#![allow(clippy::derive_partial_eq_without_eq)]

aws/rust-runtime/aws-hyper/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
#![deprecated(
710
since = "0.3.0",
811
note = "The functionality of this crate is included in individual AWS services."

aws/rust-runtime/aws-inlineable/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! Collection of modules that get conditionally included directly into the code generated
710
//! SDK service crates. For example, when generating S3, the `s3_errors` module will get copied
811
//! into the generated S3 crate to support the code generator.

aws/rust-runtime/aws-runtime-api/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! Runtime support code for the AWS SDK. This crate isn't intended to be used directly.
710
811
#![warn(

aws/rust-runtime/aws-runtime/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! Runtime support code for the AWS SDK. This crate isn't intended to be used directly.
710
811
#![warn(

aws/rust-runtime/aws-sig-auth/src/lib.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,7 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55

6+
/* Automatically managed default lints */
7+
#![cfg_attr(docsrs, feature(doc_auto_cfg))]
8+
/* End of automatically managed default lints */
69
//! This crate is no longer used by the AWS SDK and is deprecated.

0 commit comments

Comments
 (0)