Improve bug message in check_ty
This branch was hit in Clippy and I think it would be nice to
show the thing that was unexpected in the bug message.
It's also in line with the other `bug!` messages in `check_ty`.
}
},
- Node::GenericParam(param) => match param.kind {
+ Node::GenericParam(param) => match ¶m.kind {
hir::GenericParamKind::Type {
default: Some(ref ty),
..
} => icx.to_ty(ty),
- _ => bug!("unexpected non-type NodeGenericParam"),
+ x => bug!("unexpected non-type Node::GenericParam: {:?}", x),
},
x => {