Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/hir-def/src/hir.rs')
-rw-r--r--crates/hir-def/src/hir.rs12
1 files changed, 8 insertions, 4 deletions
diff --git a/crates/hir-def/src/hir.rs b/crates/hir-def/src/hir.rs
index a575a2d199..c1d3e255bb 100644
--- a/crates/hir-def/src/hir.rs
+++ b/crates/hir-def/src/hir.rs
@@ -17,7 +17,7 @@ pub mod type_ref;
use std::fmt;
-use hir_expand::name::Name;
+use hir_expand::{name::Name, MacroDefId};
use intern::{Interned, Symbol};
use la_arena::{Idx, RawIdx};
use rustc_apfloat::ieee::{Half as f16, Quad as f128};
@@ -492,9 +492,13 @@ pub enum Statement {
expr: ExprId,
has_semi: bool,
},
- // At the moment, we only use this to figure out if a return expression
- // is really the last statement of a block. See #16566
- Item,
+ Item(Item),
+}
+
+#[derive(Debug, Clone, PartialEq, Eq)]
+pub enum Item {
+ MacroDef(Box<MacroDefId>),
+ Other,
}
/// Explicit binding annotations given in the HIR for a binding. Note