pub(crate) fn has_doc_flag(tcx: TyCtxt<'_>, did: DefId, flag: Symbol) -> bool
Checks for the existence of hidden in the attribute below if flag is sym::hidden:
hidden
flag
sym::hidden
#[doc(hidden)] pub fn foo() {}
This function exists because it runs on hir::Attributes whereas the other is a clean::Attributes method.
hir::Attributes
clean::Attributes