提交 c6890e17 编写于 作者: A Andrew Cann

Revert Ty::is_uninhabited to its original state

上级 a4e6009b
......@@ -906,10 +906,10 @@ pub fn is_uninhabited(&self, _cx: TyCtxt) -> bool {
// more complete.
match self.sty {
TyEnum(def, _) | TyStruct(def, _) => def.is_empty(),
TyNever => true,
// FIXME(canndrew): There's no reason why this can't be uncommented, it's tested and it
// doesn't break anything. But I'm keeping my changes small for now.
// FIXME(canndrew): There's no reason why these can't be uncommented, they're tested
// and they don't break anything. But I'm keeping my changes small for now.
//TyNever => true,
//TyTuple(ref tys) => tys.iter().any(|ty| ty.is_uninhabited(cx)),
// FIXME(canndrew): this line breaks core::fmt
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册