about summary refs log tree commit diff
path: root/compiler/rustc_attr_parsing/src/interface.rs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/rustc_attr_parsing/src/interface.rs')
-rw-r--r--compiler/rustc_attr_parsing/src/interface.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_attr_parsing/src/interface.rs b/compiler/rustc_attr_parsing/src/interface.rs
index 60523c2877c..a3558850ef3 100644
--- a/compiler/rustc_attr_parsing/src/interface.rs
+++ b/compiler/rustc_attr_parsing/src/interface.rs
@@ -271,8 +271,8 @@ impl<'sess, S: Stage> AttributeParser<'sess, S> {
                             };
 
                             (accept.accept_fn)(&mut cx, args);
-
-                            if !matches!(self.stage.should_emit(), ShouldEmit::Nothing) {
+                            if !matches!(cx.stage.should_emit(), ShouldEmit::Nothing) {
+                                Self::check_type(accept.attribute_type, target, &mut cx);
                                 self.check_target(
                                     path.get_attribute_path(),
                                     attr.span,