mirror of https://github.com/rust-lang/rust.git
Small cleanup in check_pat_path.
This commit is contained in:
parent
2887008e0c
commit
a947b75196
|
@ -1067,10 +1067,7 @@ https://doc.rust-lang.org/reference/types.html#trait-objects");
|
|||
self.set_tainted_by_errors();
|
||||
return tcx.types.err;
|
||||
}
|
||||
Res::Def(DefKind::Method, _) => {
|
||||
report_unexpected_variant_res(tcx, res, pat.span, qpath);
|
||||
return tcx.types.err;
|
||||
}
|
||||
Res::Def(DefKind::Method, _) |
|
||||
Res::Def(DefKind::Ctor(_, CtorKind::Fictive), _) |
|
||||
Res::Def(DefKind::Ctor(_, CtorKind::Fn), _) => {
|
||||
report_unexpected_variant_res(tcx, res, pat.span, qpath);
|
||||
|
|
Loading…
Reference in New Issue