let param_data = &generics.params.consts[id.local_id];
write!(f, "{}", param_data.name)
}
- ConstValue::Concrete(_) => write!(f, "_"),
+ ConstValue::Concrete(c) => write!(f, "{}", c.interned),
}
}
}
write!(f, "{}", mutability)?;
inner.hir_fmt(f)?;
}
- TypeRef::Array(inner) => {
+ TypeRef::Array(inner, len) => {
write!(f, "[")?;
inner.hir_fmt(f)?;
- // FIXME: Array length?
- write!(f, "; _]")?;
+ write!(f, "; {}]", len)?;
}
TypeRef::Slice(inner) => {
write!(f, "[")?;
}
TypeRef::Macro(macro_call) => {
let macro_call = macro_call.to_node(f.db.upcast());
- let ctx = body::LowerCtx::with_hygiene(&Hygiene::new_unhygienic());
+ let ctx = body::LowerCtx::with_hygiene(f.db.upcast(), &Hygiene::new_unhygienic());
match macro_call.path() {
Some(path) => match Path::from_src(path, &ctx) {
Some(path) => path.hir_fmt(f)?,