cargo-semver-checks 0.34.0

Scan your Rust crate for semver violations.
Documentation
SemverQuery(
    id: "trait_associated_const_now_doc_hidden",
    human_readable_name: "trait associated const is now #[doc(hidden)]",
    description: "A public trait associated const is now marked as #[doc(hidden)] and has thus been removed from the public API",
    required_update: Major,
    lint_level: Deny,
    reference_link: Some("https://doc.rust-lang.org/rustdoc/write-documentation/the-doc-attribute.html#hidden"),
    query: r#"
    {
        CrateDiff {
            baseline {
                item {
                    ... on Trait {
                        trait_name: name @output
                        visibility_limit @filter(op: "=", value: ["$public"])

                        importable_path {
                            path @output @tag
                            public_api @filter(op: "=", value: ["$true"])
                        }

                        associated_constant {
                            associated_constant: name @output @tag
                            public_api_eligible @filter(op: "=", value: ["$true"])
                        }
                    }
                }
            }
            current {
                item {
                    ... on Trait {
                        visibility_limit @filter(op: "=", value: ["$public"])

                        importable_path {
                            path @filter(op: "=", value: ["%path"])
                            public_api @filter(op: "=", value: ["$true"])
                        }

                        associated_constant {
                            public_api_eligible @filter(op: "!=", value: ["$true"])
                            name @filter(op: "=", value: ["%associated_constant"])
                            span_: span @optional {
                                filename @output
                                begin_line @output
                            }
                        }
                    }
                }
            }
        }
    }"#,
    arguments: {
        "public": "public",
        "true": true
    },
    error_message: "A const in a pub trait is now #[doc(hidden)], which removes it from the crate's public API",
    per_result_error_template: Some("associated constant {{trait_name}}::{{associated_constant}} in {{span_filename}}:{{span_begin_line}}"),
)