diff options
| author | Jana Dönszelmann <jana@donsz.nl> | 2025-06-13 13:20:45 +0200 |
|---|---|---|
| committer | Jana Dönszelmann <jana@donsz.nl> | 2025-06-13 14:03:01 +0200 |
| commit | 6f5a717a6cfe9e0bea8a67f30a1db90ccd91aee9 (patch) | |
| tree | acabc2462c832b8a81e8b303c02a8255d1200929 /compiler/rustc_ast_lowering/src | |
| parent | 015c7770ec0ffdba9ff03f1861144a827497f8ca (diff) | |
collect delayed lints in hir_crate_items
Diffstat (limited to 'compiler/rustc_ast_lowering/src')
| -rw-r--r-- | compiler/rustc_ast_lowering/src/item.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/compiler/rustc_ast_lowering/src/item.rs b/compiler/rustc_ast_lowering/src/item.rs index d1a2ddbdb34..b98868aba1f 100644 --- a/compiler/rustc_ast_lowering/src/item.rs +++ b/compiler/rustc_ast_lowering/src/item.rs @@ -145,6 +145,7 @@ impl<'hir> LoweringContext<'_, 'hir> { kind, vis_span, span: self.lower_span(i.span), + has_delayed_lints: !self.delayed_lints.is_empty(), }; self.arena.alloc(item) } @@ -599,6 +600,7 @@ impl<'hir> LoweringContext<'_, 'hir> { kind, vis_span, span: this.lower_span(use_tree.span), + has_delayed_lints: !this.delayed_lints.is_empty(), }; hir::OwnerNode::Item(this.arena.alloc(item)) }); @@ -697,6 +699,7 @@ impl<'hir> LoweringContext<'_, 'hir> { kind, vis_span: self.lower_span(i.vis.span), span: self.lower_span(i.span), + has_delayed_lints: !self.delayed_lints.is_empty(), }; self.arena.alloc(item) } @@ -941,6 +944,7 @@ impl<'hir> LoweringContext<'_, 'hir> { kind, span: self.lower_span(i.span), defaultness: hir::Defaultness::Default { has_value: has_default }, + has_delayed_lints: !self.delayed_lints.is_empty(), }; self.arena.alloc(item) } @@ -1100,6 +1104,7 @@ impl<'hir> LoweringContext<'_, 'hir> { vis_span: self.lower_span(i.vis.span), span: self.lower_span(i.span), defaultness, + has_delayed_lints: !self.delayed_lints.is_empty(), }; self.arena.alloc(item) } |
