Rollup merge of #132388 - frank-king:feature/where-cfg, r=petrochenkov

Implement `#[cfg]` in `where` clauses

This PR implements #115590, which supports `#[cfg]` attributes in `where` clauses.

The biggest change is, that it adds `AttrsVec` and  `NodeId` to the `ast::WherePredicate` and `HirId` to the `hir::WherePredicate`.
This commit is contained in:
Matthias Krüger
2025-03-03 10:40:56 +01:00
committed by GitHub
38 changed files with 3296 additions and 88 deletions

View File

@@ -2386,6 +2386,7 @@ impl<'a> State<'a> {
}
fn print_where_predicate(&mut self, predicate: &hir::WherePredicate<'_>) {
self.print_attrs_as_outer(self.attrs(predicate.hir_id));
match *predicate.kind {
hir::WherePredicateKind::BoundPredicate(hir::WhereBoundPredicate {
bound_generic_params,