SemverQuery(
id: "inherent_associated_const_now_doc_hidden",
human_readable_name: "inherent impl's associated const is now #[doc(hidden)]",
description: "An inherent impl's 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 ImplOwner {
visibility_limit @filter(op: "=", value: ["$public"])
name @output
importable_path {
path @output @tag
public_api @filter(op: "=", value: ["$true"])
}
inherent_impl {
public_api_eligible @filter(op: "=", value: ["$true"])
associated_constant {
associated_constant: name @output @tag
public_api_eligible @filter(op: "=", value: ["$true"])
span_: span @optional {
filename @output
begin_line @output
end_line @output
}
}
}
}
}
}
current {
item {
... on ImplOwner {
visibility_limit @filter(op: "=", value: ["$public"])
importable_path {
path @filter(op: "=", value: ["%path"])
public_api @filter(op: "=", value: ["$true"])
}
inherent_impl {
associated_constant {
name @filter(op: "=", value: ["%associated_constant"])
public_api_eligible @filter(op: "!=", value: ["$true"])
}
}
}
}
}
}
}"#,
arguments: {
"public": "public",
"true": true,
},
error_message: "An inherent impl's associated const is now #[doc(hidden)], which removes it from the crate's public API",
per_result_error_template: Some("{{name}}::{{associated_constant}}, previously at {{span_filename}}:{{span_begin_line}}"),
)