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.rs | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/crates/hir-def/src/hir.rs b/crates/hir-def/src/hir.rs index c1d3e255bb..8596346943 100644 --- a/crates/hir-def/src/hir.rs +++ b/crates/hir-def/src/hir.rs @@ -18,15 +18,16 @@ pub mod type_ref; use std::fmt; use hir_expand::{name::Name, MacroDefId}; -use intern::{Interned, Symbol}; +use intern::Symbol; use la_arena::{Idx, RawIdx}; use rustc_apfloat::ieee::{Half as f16, Quad as f128}; use syntax::ast; +use type_ref::TypeRefId; use crate::{ builtin_type::{BuiltinFloat, BuiltinInt, BuiltinUint}, path::{GenericArgs, Path}, - type_ref::{Mutability, Rawness, TypeRef}, + type_ref::{Mutability, Rawness}, BlockId, ConstBlockId, }; @@ -264,7 +265,7 @@ pub enum Expr { }, Cast { expr: ExprId, - type_ref: Interned<TypeRef>, + type_ref: TypeRefId, }, Ref { expr: ExprId, @@ -300,8 +301,8 @@ pub enum Expr { }, Closure { args: Box<[PatId]>, - arg_types: Box<[Option<Interned<TypeRef>>]>, - ret_type: Option<Interned<TypeRef>>, + arg_types: Box<[Option<TypeRefId>]>, + ret_type: Option<TypeRefId>, body: ExprId, closure_kind: ClosureKind, capture_by: CaptureBy, @@ -318,7 +319,7 @@ pub enum Expr { #[derive(Debug, Clone, PartialEq, Eq)] pub struct OffsetOf { - pub container: Interned<TypeRef>, + pub container: TypeRefId, pub fields: Box<[Name]>, } @@ -484,7 +485,7 @@ pub struct RecordLitField { pub enum Statement { Let { pat: PatId, - type_ref: Option<Interned<TypeRef>>, + type_ref: Option<TypeRefId>, initializer: Option<ExprId>, else_branch: Option<ExprId>, }, @@ -582,7 +583,7 @@ pub enum Pat { suffix: Box<[PatId]>, }, /// This might refer to a variable if a single segment path (specifically, on destructuring assignment). - Path(Box<Path>), + Path(Path), Lit(ExprId), Bind { id: BindingId, |